3. Thereās what youāll find in this section :
ā¢ Setting up Enviroment
ā¢ Constants
ā¢ Mathmatical operations
ā¢ C Variables and data types
ā¢ Conditions
ā¢ Loops
ā¢ Functions
ā¢ Arrays
Overview
MillerOpenUniversity
4. 02:Functions
ā¢ You can think of function as a black box take an input and
produce an output and itās not important to know what is the
algorithm inside of it , just enough to know how you can use
and what is their function.
Hello,World
5. 03:Constants
ā¢ Fixed values such as numbers, letters, and strings are
called āconstantsā
ā¢ String constants use single quotes (') or double quotes (")
7. 05:Variables
ā¢ You can think of variable as a little box or a container to
store data in the memory of the computer and later
retrieve the data using the variable ānameā
ā¢ Programmers get to choose the names of the variables
ā¢ You can change the contents of a variable in a later
statement
8. 06:AssignmentStatements
ā¢ We assign a value to a variable using the assignment
statement (=)
ā¢ An assignment statement consists of an expression on
the right-hand side and a variable to store the result
11. 09:CommentsinC
ā¢ One line Comments in C begin with a //
ā¢ Multiple line Comments in C begin with a /* and ends
with ( */
ā¢ when you run a program you will not see any indication
of the comment there. Comments are in the source
code for humans to read, not for computers to execute.
12. 10:UserInput
ā¢ C has an scanf function which lets you ask a user for
some integer, char or float input.
ā¢ And gets function for asking a user for some text input.