introduction demo1 (1)
DESCRIPTION
Introduction to CNG labsTRANSCRIPT
![Page 1: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/1.jpg)
Brief Information on
CNG230 Labs
Spring 2013
Week 1
![Page 2: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/2.jpg)
Content• Lab Requirements
– Weekly Program– Lab Task
• METU-Online (for recent announcements, course materials)
• Environment/Compiler to be used– Dev-C++ Compiler– How to obtain?– How to compile and run?
![Page 3: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/3.jpg)
Lab Requirements
• Students who do not attend 3 or more labs will fail from the course!!!
• A lab test will be given and is to be solved during lab hours. Lab grade will mainly depend on it.
• The lab task will be a programming exercise which you
will do during the lab hours on your own. It will be an INDIVIDUAL task so you cannot cooperate!
![Page 5: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/5.jpg)
![Page 6: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/6.jpg)
TO DOWNLOAD Dev-C++
http://sourceforge.net/project/downloading.php?group_id=10639&use_mirror=mesh&filename=devcpp-4.9.9.2_setup.exe&1522775
![Page 7: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/7.jpg)
Creating a new source file:
![Page 8: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/8.jpg)
Area where code is written
![Page 9: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/9.jpg)
Compiling the source file (3 ways):
1) File menu > Execute, 2) Icon on toolbar 3) Shortcut keys (CTRL+F9)
![Page 10: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/10.jpg)
No error in the code, so we can run the executable file
![Page 11: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/11.jpg)
Running the executable file (3 ways):
1) File menu > Execute, 2) Icon on toolbar 3) Shortcut keys (CTRL+F10)
![Page 12: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/12.jpg)
After running the executable file, you see the output:
![Page 13: Introduction Demo1 (1)](https://reader036.vdocument.in/reader036/viewer/2022062715/55cf91ce550346f57b90d6ff/html5/thumbnails/13.jpg)
After compiling, you may encounter compile errors which you must eliminate in order to have an executable file
You see an example below. Dev-C++ shows you where the errors are. You should understand cause(s) of the errors and fix them. After getting a hands-on experience with your compiler, you will be able to obtain error-free codes.