Section 1
Section 1
Programming
Using C#
By 2024-2025
• Subject Objectives
– Understand the Basics of Structure Programming.
– Fundamentals of Programming in C#
• Programming language types.
• Translators.
• Error types.
Part I
• Introduction to programming
• Visual studio GUI
• Basic lines of Code
Why Programming?
• Automation:
Example: Automated online checkout systems in stores save time and reduce errors.
• Innovation(new technologies):
Example: Companies like Tesla use programming to develop advanced self-driving technology.
• Problem Solving:
Example: Programmers develop apps that help users manage their health, such as fitness trackers
that monitor physical activity.
• Data Handling:
Example: Social media platforms like Facebook analyze user data to suggest friends and
content, enhancing user experience.
• Building Technology:
Example: Websites like YouTube rely on programming to create, upload, and stream videos
efficiently.
Why Programming?
Cont.
Applications of Programming
• Healthcare: Used in medical devices and patient records.
• Finance: Powers banking systems and online transactions.
• Education: Enhances learning through online platforms.
• Entertainment: Creates video games and movies.
• Transportation: Important for traffic management and self-
driving cars.
What is a computer?
Software Definition
• High Level
• Intermediate (Assembly)
• Low Level (0/1)
• There is no better.
• For performance-critical applications, compilers
are often preferred due to faster execution times.
• Syntax Error.
• Semantic Error.
• Runtime Error.
Syntax Error
• Syntax is like Grammar rules in English Language.
Example: "She go to school yesterday.“
• Console.WriteLine("Hello World"
• When you run this code it will result in Syntax Error
due to the missing )
Example:
• Dividing by zero.
• Reading from a file that doesn’t exist.
What is C#
• https://visualstudio.microsoft.com/downloads/
Current Namespace
Console Class
WriteLine Method
What is Console
Console Class
• Console.Write();
• Console.WriteLine( );
• Console.ReadLine();
• Console.ReadKey();
Code with me
• Try \a
Practice 1: