Solved

writing a c programme  in  a  unix  environment

Posted on 1998-10-14
3
215 Views
Last Modified: 2010-04-15
I just  started programming in C and  I need to  write a  C   programme
in  Unix.   How do I start?
0
Comment
Question by:naturalmystic
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
3 Comments
 
LVL 2

Expert Comment

by:shchuka
ID: 1253525
You should use any text editor to write the source code, e.g. vi, emacs, pico, or anything else.  I personally recommend emacs.  If you're working on a workstation, it has C syntax coloring and it will automatically match parenthes (all kinds: (), [], {}). Start it by typing at the command prompt:
    emacs filename.c
After you've created the file, compile it using gcc or cc or whatever compiler is available on your system:
    gcc -o outputfilename filename.c

This is the simplest thing you would do.  Of course, if you're working on a large project, you'll have a make file to compile the sources and also you'll probably use some flags to pass to the compiler.  From you question, I believe you are just starting working with C, so my answer should be enough to get you started.
0
 
LVL 2

Accepted Solution

by:
kellyjj earned 50 total points
ID: 1253526
Are you new to C??  If so I would get some books to  get you started.  There are pleanty good books out there.  Then just start doing the excercises in the books.   Also I would get a book dealing with unix.


0
 

Author Comment

by:naturalmystic
ID: 1253527
Thanks kellyjj for attempting an answer but I found schuka's comment more helpful.THANKS  A LOT SCHUKA.WHAT BOOKS ARE YOU TALKING  ABOUT KELLYJJ?
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Windows programmers of the C/C++ variety, how many of you realise that since Window 9x Microsoft has been lying to you about what constitutes Unicode (http://en.wikipedia.org/wiki/Unicode)? They will have you believe that Unicode requires you to use…
This is a short and sweet, but (hopefully) to the point article. There seems to be some fundamental misunderstanding about the function prototype for the "main" function in C and C++, more specifically what type this function should return. I see so…
Video by: Grant
The goal of this video is to provide viewers with basic examples to understand and use nested-loops in the C programming language.
The goal of this video is to provide viewers with basic examples to understand opening and reading files in the C programming language.
Suggested Courses

732 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question