#Lesson 1 |
#Lesson 2 |
Intro to Dev C ++
In this lesson, we introduce you to the basic of C Programming using the DevC++ IDE tool. We cover the steps involved in creating a project, editing the code, compiling it and executing it.
|
Holding the Output Screen from the .exe File
We saw that when we successfully compile and run the code, we generate a .exe file. this video shows us how we can hold the output screen when we execute the program directly through the .exe file.
|
#Lesson 3 |
#Lesson 4 |
Using scanf for User Input
|
if-else Statements
|
We are now ready to accept inputs from the user. In this video, we are going to look at how we can capture the keyboard input using the scanf() function.
|
Most software programs do not run from line 1 all the way till the end. Certain parts of the code should be executed only when certain conditions are met. This is achieved through program-flow statements, also known as decision -making blocks. The most common way of doing this in a software is through the use of if-else statements.
|
|
|
#Lesson 5 |
#Lesson 6 |
if, else-if with AND operator
|
if-else with OR operator
|
When the decision involves checking multiple conditions, then we need to incorporate logical operators to help us. When ALL conditions need to be fulfilled, then we need to use the AND operator together with the if-else statements. In the case where there are more than TWO possible outcomes, we need to replace the if-else with a series of if, else-if, else-if,..., else statements.
|
In situations where there there are a few conditions, and we are checking to see if ANY ONE of those conditions are satisfied, then we use the OR operator together with the if-else statements.
|
|
|
Review Question 1
Q1. Prompt the user to enter 3 marks, one at a time.
After obtaining the three numbers, compute the average mark.
Proceed to provide a Grade, based on the average mark.
After obtaining the three numbers, compute the average mark.
Proceed to provide a Grade, based on the average mark.
#Lesson 7 |
#Lesson 8 |
Pointer Basics
|
Functions - No Input Parameters and No Return Value
|
Pointers play a critical role in C Programming. In this video we explore the use of pointers and how they can be assigned to different variables.
|
The overall aim of the software can be modularized into functions, with each function fulfilling a particular task. This makes it easier to approach the solution in a more structured way and also collaborate with others.
|
|
|
#Lesson 9 |
#Lesson 10 |
Functions - No Input Parameters with Single Return Value
|
Functions - Input Parameters with Single Return Value
|
Now we explore how we can return a value from a function.
|
We now look at how a function can accept input parameters and generate a return value.
|
|
|