Table of Contents

cprog Keywords

cprog Keyword 1

Standard I/O

Definition

The normal input and output methods of your machine

Demonstration

Your standard input for most machines is the keyboard
Your standard output for most machines is the monitor
fprintf(stdout,“you win”)
scanf(stdin,“%s”, word)

cprog Keyword 2

Header Files

Definition

A header file is a file that the compiler loads and writes into your c file before compiling your own code.
This adds basic functions depending on the header file loaded

Demonstration

Header files are usually written as #include <headername.h>

cprog Keyword 3

Pointers

Definition

Pointers are a block of ram that points to another part of ram.

Demonstration

When you have a pointer, its ram block holds a specific address. That address is the address of what it is connected to. For example we have two variables, one is a point A, and one is just a normal variable B.

We declare that B = 5. We declare that A points to the location of ram where B is. When we call for A itself, it shows us the address of B. When we call A as a pointer, it shows us what is in B, in this care, 5.

cprog Keyword 4

Arithmetic

Definition

Changes to numbers.

Demonstration

There are a several different arithmetic's symbols, a few examples are /,*,-,+. Each one does something different to a number. For example, 2+2. Takes the number 2, adds 2 to it, and makes it 4.

cprog Keyword 5

Type Casting

Definition

Forcing one type of value to act as another.

Demonstration

int help

(char)help

there i am forcing help to act as a char, even though its an int.

cprog Keyword 6

Selection Structures.

Definition

Telling the computer to do something if a specific case is true.

Demonstration

int a int b a = 2 b = 2 if (a == b) {

  a = b + 1

} return()

telling it that if a and b are the same, then make b equal to a + 1.

cprog Keyword 7

Repetition structures.

Definition

Doing the same process over again so long as something is true.

Demonstration

while (x == b) {

 x = b + 1

} return()

doing this loop only once in this situation, but the idea is there so long as x equals b, it will make x = b + 1

cprog Keyword 8

Identification of chosen keyword (unless you update the section heading above).

Definition

Definition (in your own words) of the chosen keyword.

Demonstration

Demonstration of the chosen keyword.

If you wish to aid your definition with a code sample, you can do so by using a wiki code block, an example follows:

/*
 * Sample code block
 */
#include <stdio.h>
 
int main()
{
    return(0);
}

Alternatively (or additionally), if you want to demonstrate something on the command-line, you can do so as follows:

lab46:~$ cd src
lab46:~/src$ gcc -o hello hello.c
lab46:~/src$ ./hello
Hello, World!
lab46:~/src$ 

cprog Objective

cprog Objective

State the course objective

Definition

In your own words, define what that objective entails.

Method

State the method you will use for measuring successful academic/intellectual achievement of this objective.

Measurement

Follow your method and obtain a measurement. Document the results here.

Analysis

Reflect upon your results of the measurement to ascertain your achievement of the particular course objective.