0% found this document useful (0 votes)
83 views3 pages

Cit301 2023 - 2

This document outlines the examination details for the course CIT301: Structured Programming at the National Open University of Nigeria. It includes instructions for answering questions, a variety of programming-related questions covering topics such as modularity, string functions, low-level languages, C programming syntax, and control structures. The exam consists of multiple questions requiring both theoretical explanations and practical coding tasks.

Uploaded by

Michael Owoh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
83 views3 pages

Cit301 2023 - 2

This document outlines the examination details for the course CIT301: Structured Programming at the National Open University of Nigeria. It includes instructions for answering questions, a variety of programming-related questions covering topics such as modularity, string functions, low-level languages, C programming syntax, and control structures. The exam consists of multiple questions requiring both theoretical explanations and practical coding tasks.

Uploaded by

Michael Owoh
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

Study Centre: Emevor Community Study Centre (DE02)

NATIONAL OPEN UNIVERSITY OF NIGERIA


PLOT 91, CADASTRAL ZONE, NNAMDI AZIKIWE EXPRESSSWAY, JABI-ABUJA

FACULTY OF SCIENCES
DEPARTMENT OF COMPUTER SCIENCE
2023_2 EXAMINATIONS 2023SEM2

COURSE CODE: CIT301

COURSE TITLE: STRUCTURED PROGRAMMING

COURSE CREDIT: 3 UNITS

TIME ALLOWED: 2 HOURS

INSTRUCTION: ANSWER QUESTION 1 AND ANY OTHER THREE QUESTIONS

Q1.
(a) Compare modularity to monolithic systems?
3 marks
(b) Differentiate between call by value and call by reference?
4 marks
(c) Describe with a C statement, 4 common string functions you know?
4 marks

(d) A transport company contracts you to publish the steps for transporting passengers from one
city to another. Using the first four phases of program development and respective tools,
practically implement the process.
14 marks
Q2.
(a) Discuss 4 characteristics of low-level languages
8 marks
(b) Tabulate 3 dissimilarities between semantic and runtime errors?
6 marks

www.puredu.net
Study Centre: Emevor Community Study Centre (DE02)

(c) List two things contained in a program documentation:


1 mark

Q3
(a) What are the character set used C programming language? Put your response in a tabular
format.
4 marks
(b) Describe 3 rules for constructing integer constants
3 marks
(c) Declare a variable for each of the following C data type: integer, float, double, and
character and assign appropriate data value at the pointer of declaration.
4 marks
(d) What is a statement? Give 2 examples.
4 marks

Q4.
(a) What will the following code segment give? Execute the code manually and give the
result:
#include<stdio.h>
void main ()
{ int a;
a=5;
for (k=1;k=4;k++)
{
while (a>=1)
{
printf ("%d",a); a--;
} printf("\n");
a= 10;
}
}
5 marks

(b) Distinguish between if-else if statement and the switch statement using the following
features: syntax, usage and expression?
6 marks

www.puredu.net
Study Centre: Emevor Community Study Centre (DE02)

(c) Write a C program to print EVEN or ODD depending on the integer number supplied
4 marks

Q5
(a) Execute manually, the following programming code:
main( )
{
int i = 2;
switch ( i )
{
case 1:
printf ( "Case 1 executing\n" ) ;
case 2:
printf ( "Case 2 executing\n" ) ;
case 3:
printf ( "Case 3 executing\n" ) ;
default :
printf ( "Default executing\n" ) ;
}
}

3 marks
(b) In C, what is the equivalent statement for switch?
1 mark
(c) Rewrite the code in (a) using if else if statements?
6 marks
(d) Write a C function to generate n odd numbers?
5 marks

Q6
(a) Differentiate between an object and executable files?
6 marks
(b) What is a compound statement? Using a pseudocode, distinguish between a for and while
block/structure?
9 marks

www.puredu.net

You might also like