Instructor-Led Red Hat Training

Intermediate C Programming

5 days

This course will present the syntax and constructs of the ISO Standard C programming language. Programs in the course are designed to work on any Linux platform that supports a C 99/11 language compiler. The course objective is to introduce intermediate and advanced level concepts and techniques of the ISO C standard language. The goal is to have participants at a functional coding level by the completion of the course. The course will be delivered on a Linux platform, using the gcc compiler suite, along with profiling tools.

Prerequisites: Introduction to C or equivalent experience and participant has used an interactive computer system, specifically, use of a text-file editor.

 

Course Outline

 

C language background

C language timeline

C programming structure

main routine layout

C data types

statements used to allocate storage

radix specifiers

classes of variables

auto

static

register

typedef 

Basic operators

unary

binary

logical

conditional

cast(ing)

bitwise (left and right shift)

sizeof

Beginning input and output in C

printf( ) function

scanf( ) function

Commands for C program development

editor development / IDE

compile

link

run (and attributes / layout)

documentation

Linux man(ual) pages

Loop constructs

for statement

while statement

do while statement

break

continue

Decision statements

if blocks

if - then

if - then - else

if - then - else if

switch block

Arrays

layout

dimensioning

single / multiple

accessing

(character) strings

Character string operations

null-terminated strings

C run-time string functions

Structures

struct statement

accessing structure members

structures containing arrays

structures containing structures

structures containing bit/flag fields

single- and double-linked

Defining and using functions

prototyping

data declarations

passing arguments

by value

by address / location / pointer

returning values

File I/O operations

the FILE structure

standard C file functions

interfacing with the command line (argv)

Defining macros

pre-processor directives

including directives at compile time

conditional compilation

usage in bit-level operations

header file

definition

usage

Pointers

concepts and rationale

usage

with atomic data types

with indexed arrays

with structures

with functions

with character strings

void

Dynamic memory

malloc( )

calloc( )

realloc( )

free( )

Variable argument lists

the va_ functions and macros

Debugging and profiling

symbolic debugging

gdb

profiling

gprof

gcov

assert( )

C programming standards

C99 / C11 standards additions / modifications

 

Back to top