Sunday 19 February 2012

Creating, Editing and Saving C program

128 x 128 black c gif icon image
Dear Readers,
       In this lesson following topics are covered...
  • Creating C Program
  • Editing C Program
  • Saving C Program

SO FRIENDS LETS START OUR LESSON
               You can write, edit and save a C program in any text editor program. But Turbo C provides a complete IDE for this purpose. You can easily write, edit and save C program in TC editor.
  • Creating C Program :-

                  The process of writing a new C program by following the rules of C language is called creating a C program. To write a new C program, load the TC editor and type the source code of program.
  • Editing C Program :-
   
                    You can also make changes during writing new programs as well as in the exiting C program. Therefore, the process of writing, changing and revising the source code is called editing program.
  • Saving C Program :-
 
                        After writing or editing the source program, you should save it on the disk as text file with an extension " .c ". This process is called saving the program.
                         To save source code in TC editor, follow these steps.
  • Select Save command from file menu or press F2 key. A dialog box will appear. The default file name of source code is NONAME00.C
  •     Type the name of file such as "first.c" and press Enter key. You can also select a specific folder (or location). where you want to save the file. Turbo C editor automatically assigns the file extension as " .c "



Note:-
                                            You can also compiler and run C program in Turbo C IDE without saving it first but it is not a good practice. You must save the program before compiling and executing it. It is because sometimes your program may be hanged during execution and your source program code may be erased from the main memory.

2 comments:

  1. Are it has another way to save program in c with out using .c

    ReplyDelete
  2. .c is the necessary extention needed to save

    ReplyDelete