Professional Documents
Culture Documents
Lab 1
Lab 1
Lab 1
Spring 2024
Introduction to C Programming
Objective:
1. Understand the basic structure of a C compiler and program.
2. Write a simple program to print text on the screen.
Task 1:
Familiarize yourself with the compiler.
Explanation:
Task 2:
What is basic c-program structure and mention the use of each line.
Code:
Explanation:
Task 3:
Print the message "Hello, C Programming!" to the console.
Code:
Output:
Explanation:
Task 4:
Print your name and registration number to the console.
Code:
Output:
Explanation:
Task 5:
Print your name and registration number to the console in the new line.
Code:
Output:
Explanation:
Task 6:
Print a string containing special characters (e.g., newline, tab).
Code:
Output:
Explanation:
Conclusion: