Like Tree3Likes

Guidance needed

This is a discussion on Guidance needed within the General Discussions forums, part of the Community Boards category; Hello forumers, I am new to C programming. It has just been a month in learning C. I used to ...

  1. #1
    Registered User
    Join Date
    Nov 2011
    Posts
    83

    Guidance needed

    Hello forumers,

    I am new to C programming. It has just been a month in learning C. I used to program a lot in VB. It seems that even for one simple program a longer c code is needed than it would be in Visual Basic.

    Can anyone give me the advantages and to what area the c programming can be applied considering only the basics of C that I have learnt?

  2. #2
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Well, you could start with Operating Systems... Windows, Linux, BSD... all written in C.
    Next you can look at compilers... C (of course), C++, C#, Visual Basic, etc. all written in C.
    Then of course there are major applications... MS Office, Star Office, Web Browsers, Inventory, Accounting, etc... again written in C
    Add to that all the server code, network management... you name it, C can do it.

    Moreover, I doubt that for programs of reasonable complexity VB is any more compact than C... I've seen lots of VB source code in my day and I'd have to suggest that most often it's a lot more verbose and longer than C source code.

  3. #3
    Registered User
    Join Date
    Nov 2011
    Posts
    83
    Oh thank you. I generally used to program with windows application but to make the same in C/C++ you have to do a lot of stuffs. Registering a class, creating a handle and then creating a window.

    I just want to ask how would a beginner start of with? What should I choose to make as a starter in C programming?
    Thank you!

  4. #4
    Registered User whiteflags's Avatar
    Join Date
    Apr 2006
    Location
    United States
    Posts
    7,707
    You're acting like every programmer takes a beaten path to a career. I'm willing to bet most careers aren't like that.

    But since you asked the question, have you thought of any problem you can solve with computers? If so, go do it. Practicing and pushing boundaries is really important. For one thing, you find out if you really like programming enough to do it every day for work.

  5. #5
    Registered User
    Join Date
    Nov 2011
    Posts
    83
    Thank you for the heads up. But really I cant find anything to do even programming interests me a lot. I will be willing to do something if I get benefit out of it. And pushing the boundaries require quite a lot of time.

    Well, in the mean time, I am just getting to know about linux. Will this benefit me?

  6. #6
    spurious conceit MK27's Avatar
    Join Date
    Jul 2008
    Location
    segmentation fault
    Posts
    8,300
    Quote Originally Posted by Swoorup View Post
    Well, in the mean time, I am just getting to know about linux. Will this benefit me?
    That depends. If the computer is just a tool to you -- something you use to accomplish a task, such as programming software, so that you can make money to pay bills -- and you are already comfortable in an environment like windows -- and you figure the significant programming you do is MS specific -- and you are not interested in history or the WWW -- I think linux will just be a sidetrack.

    But if the computer is also a bit of a toy, something you play with, or something you are fascinated by, and this is why you are attracted to programming, then you'll love linux. Which is not to say windows is for serious people and linux is for clowns .

    From a C programming perspective, linux (the OS kernel) is also interesting because it is open source and written in C, as is all of the essential GNU userland stuff that makes GNU/linux an "operating system". You're not going to get to see the source code for Windows 7 or OSX anytime soon, but you can with linux. The consequences of that are still unfolding, eg, Android, which apparently now runs most of the world's smartphones, started with the linux source code:

    Quote Originally Posted by wikipedia
    Android consists of a kernel based on the Linux kernel, with middleware, libraries and APIs written in C and application software running on an application framework which includes Java-compatible libraries based on Apache Harmony. Android uses the Dalvik virtual machine with just-in-time compilation to run Dalvik dex-code (Dalvik Executable), which is usually translated from Java bytecode.
    I'd bet $$ the linux kernel is used in more diverse environments than any other OS kernel ever. And again: it's open source, written in C...

    Even if you aren't a programmer, linux is very interesting culturally, in so far as it is not produced by a business model, and demonstrates all the advantages (and disadvantages) of that. Unique, contemporary real world examples like that are hard to come by. IMO, this makes it a qualitatively different beast than other popular OS's. It may not be for the faint of heart tho, lol.

    Last edited by MK27; 11-19-2011 at 06:24 AM.
    manasij7479 and Swoorup like this.
    C programming resources:
    GNU C Function and Macro Index -- glibc reference manual
    The C Book -- nice online learner guide
    Current ISO draft standard
    CCAN -- new CPAN like open source library repository
    3 (different) GNU debugger tutorials: #1 -- #2 -- #3
    cpwiki -- our wiki on sourceforge

  7. #7
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by Swoorup View Post
    Oh thank you. I generally used to program with windows application but to make the same in C/C++ you have to do a lot of stuffs. Registering a class, creating a handle and then creating a window.
    Trust me... Visual Basic did all those things too... it just hid them from you.

    C does not babysit...

    I just want to ask how would a beginner start of with? What should I choose to make as a starter in C programming?
    Thank you!
    First you should visit... TheForger

    From there start with a couple of simple programs... do stuff like learning how to create a window, working with child controls, etc. There are certain concepts and requirements you need to understand before you're going to do much and it's often best to test each in isolation rather than trying to understand the whole thing as one big blob.

    Practical programs are most often a "mother of invention" thing where the need creates the result... My first C project was a MIDI file player/editor, but I sincerely wish I'd started with something simpler, like balancing my chequebook or amortizing my mortgage... The less complex projects would have helped me understand many of the concepts better.
    Last edited by CommonTater; 11-19-2011 at 08:17 AM.

  8. #8
    Registered User
    Join Date
    Nov 2011
    Posts
    37
    Quote Originally Posted by CommonTater View Post
    Trust me... Visual Basic did all those things too... it just hid them from you.

    C does not babysit...
    I think this is the comment of the year!

    I met some people that weren't really interested in computers and went to study it anyway, they were not happy.
    Don't you like something else that can provide money?

  9. #9
    Registered User
    Join Date
    Nov 2011
    Posts
    83
    Thank you MK27, CommonTater and Walla.

    I don't like anything other things than computing. I sit on my computer all day. Even though I was the best in my class (good old VB offcourse) I find c, linux, ASM difficult and time consuming to learn though. It brings me a lot of frustration. Feels that I will not get a good job. I wished my school and college had taught me C/C++ before.

    I know it can do a lot of things and is very transparent, near to ASM. But I just don't understand what project should I be involved in, just to begin with. The knowledge I have learnt took almost 2 months and still nothing I could do.

    Anyway thank you guys

  10. #10
    Banned
    Join Date
    Aug 2010
    Location
    Ontario Canada
    Posts
    9,547
    Quote Originally Posted by Swoorup View Post
    I find c, linux, ASM difficult and time consuming to learn though.
    Because they are.


    I know it can do a lot of things and is very transparent, near to ASM. But I just don't understand what project should I be involved in, just to begin with. The knowledge I have learnt took almost 2 months and still nothing I could do.
    Trust me... 2 months is a drop in the bucket. I've been coding in C since 2004 and the guys here are still showing me new stuff on a near daily basis.

    There is something of a secret here... Don't Compare... I see you constantly referring to VB as your standard and comparing C to it. You won't learn C that way. Clear your head of VB and learn C as a brand new undertaking... much like you would set aside your English to learn French. Trying to compare them is going to constantly trip you up.
    Swoorup likes this.

  11. #11
    Registered User
    Join Date
    Nov 2011
    Posts
    83
    Thank you for the advice. So I should totally eradicate VB out of my head?
    Just one question. If I need to program a solution that needs to be done quickly, can I program in C# for the simplicity?
    I heard that it will benefit in learning C/C++ too? That way, I could get done with my projects and learn C at the same time too.

    Again thank you!

    EDIT: What would you say about jobs that programming offer? Does it have good scope or will it pay me well? I watched some cartoons depicting that employer wants too many out of a programmer. He should know oracle, C++. java, php, html, python, Vbasics, UML, XML,.
    That scared the ........ out me! I always want to choose computing as my career.
    Last edited by Swoorup; 11-19-2011 at 09:25 PM.

  12. #12
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    21,749
    Quote Originally Posted by Swoorup
    So I should totally eradicate VB out of my head?
    No, just keep in mind that what you know of VB does not necessarily apply to other programming languages, so don't assume that you already know something because you encountered something akin to it in VB.

    Quote Originally Posted by Swoorup
    If I need to program a solution that needs to be done quickly, can I program in C# for the simplicity?
    I am not sure what exactly are you asking. If you are really asking "can I?", then I would ask you back: can you? Or perhaps I would devise a test of your C# programming abilities.

    I suspect that you are really asking "is C# suitable to develop a solution that needs to be done quickly?" The answer would then depend on what exactly is this solution that you need to program, your skills (and that of your team mates) in C#, and various other factors.

    Quote Originally Posted by Swoorup
    What would you say about jobs that programming offer? Does it have good scope or will it pay me well?
    Your mileage may vary

    Quote Originally Posted by Swoorup
    I watched some cartoons depicting that employer wants too many out of a programmer. He should know oracle, C++. java, php, html, python, Vbasics, UML, XML,.
    I have heard of job advertisements where applicants are expected to have n number of years experience in a technology developed less than n number of years ago. Go figure
    C + C++ Compiler: MinGW port of GCC
    Version Control System: Bazaar

    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  13. #13
    Registered User manasij7479's Avatar
    Join Date
    Feb 2011
    Location
    Kolkata@India
    Posts
    2,498
    >I find c, linux, ASM difficult and time consuming to learn though.
    Not to discourage you... but you really should not try to learn too much at once. That would take much more time that the sum of the individual ones, and will be more confusing for you to grasp.
    Manasij Mukherjee | gcc-4.8.2 @Arch Linux
    Slow and Steady wins the race... if and only if :
    1.None of the other participants are fast and steady.
    2.The fast and unsteady suddenly falls asleep while running !



  14. #14
    Unregistered User Yarin's Avatar
    Join Date
    Jul 2007
    Posts
    1,628
    Quote Originally Posted by CommonTater View Post
    Trust me... 2 months is a drop in the bucket. I've been coding in C since 2004 and the guys here are still showing me new stuff on a near daily basis.
    Heh, so have I, since early 04.
    And yes, 2 months is nothing. (I didn't even know what a pointer was by that time.)

  15. #15
    Registered User
    Join Date
    Nov 2011
    Posts
    83
    Well, I was getting to know about pointers and even function pointers until someone locked up my topic saying that hacking is not allowed. BTW it was on GTAForums. And R* always allowed modifications

    Does not matter though.
    @laserlight I don't know if I can, but just want to learn it too and get off with VB. And is it similar to C? If it is, then won't it help me in learning C?

    @manasij
    Exactly. But the way I learn things is quite not practical or others. Anyway her it is:

    I think that ASM, linux and C are all related to each other very much, so learning one would help me learn the other at the same time.
    Also the main point which why lead me to study all at once is that, if I get stuck at one point then I would be learning the other. Because if I would be sticking with the problem of the first one, then it would be a lot time consuming and would just take a week or too to figure out that.
    And also by learning other things I come across terms and the cause/solution of the first problem.

    Here is an example: I used to see some codes containg _cdecl ,_stdcall or fastcall.
    Then I said to myself what the hell, why is that hard to learn. Then I went through ASM, and I got to know its just the standards of calling convention or the way parameters are passed.

Page 1 of 2 12 LastLast
Popular pages Recent additions subscribe to a feed

Similar Threads

  1. I need guidance.
    By FieryAbyss in forum C++ Programming
    Replies: 2
    Last Post: 10-21-2010, 10:52 PM
  2. Guidance needed, is this good programming??
    By turnr in forum C Programming
    Replies: 12
    Last Post: 05-21-2010, 10:46 AM
  3. Little guidance please...
    By Jayhawk_26 in forum C Programming
    Replies: 5
    Last Post: 10-09-2006, 01:27 AM
  4. Guidance Needed...
    By able in forum C Programming
    Replies: 1
    Last Post: 06-28-2006, 11:59 PM
  5. Guidance needed!!
    By pdstatha in forum C++ Programming
    Replies: 2
    Last Post: 06-22-2002, 09:22 AM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21