0% found this document useful (0 votes)
2 views

Visual Programming Tutorials Outline

The document outlines a visual programming tutorial for C# held on May 17 and 20, 2023, covering topics such as programming elements, sequence structures, selection structures, iteration, arrays, functions, and object-oriented programming. Each topic includes examples and extension work for students to practice. The tutorial is facilitated by tutor Jacob Zvirikuzhe, with a focus on practical applications and programming exercises.

Uploaded by

Antonate
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views

Visual Programming Tutorials Outline

The document outlines a visual programming tutorial for C# held on May 17 and 20, 2023, covering topics such as programming elements, sequence structures, selection structures, iteration, arrays, functions, and object-oriented programming. Each topic includes examples and extension work for students to practice. The tutorial is facilitated by tutor Jacob Zvirikuzhe, with a focus on practical applications and programming exercises.

Uploaded by

Antonate
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 3

VISUAL PROGRAMMING ONLINE TUTORIALS OUTLINE

BITH 231 & BSIT 231


17 & 20 MAY 2023
PROGRAMMING LANGUAGE: C# Assist Tutor: Jacob Zvirikuzhe Cell: 0779335907
TIME/Date TOPIC/SUB TOPIC EXAMPLES/NOTES Extension work
Day 1 Visual Programming Programming elements graphically
17/05/2023 ▪ Expectations in rather than specifying using text
Visual
Programming
C# Environment Ex 1: The “Hello” Program
▪ Console Application A program to say Hello to a friend and
▪ Forms Application the world using Console Application
and Windows IDE.
Individual Work: A Forms Application
program to show the name of your
university when a button is clicked
Sequence Structures Ex 2: A program to find the sum of two 1. Write a program for
▪ Variables and numbers. converting temperature
constants Ex 3: A company is currently offering a from degrees Celsius to
▪ Basic sequence big sale. It is offering 15% discount on Fahrenheit. The formula
structure problem all products. Write a program that is C = (F-32)/1.8
▪ Word problem on prompts the user to enter product name 2. Design an interface
sequence structure and price. The program must display and write a program that
the discounted and resultant prices. allows the user to input 2
integer values and swap
them.
Selection structures Ex 4: A program to grade marks 3. Design a program that
▪ IF structure: single, dual, basing on grading criteria. can determine of an
multiple Individual Work: A program to input year is a leap year
▪ determine if a number is negative, or nor. If it’s a leap year
▪ Nested IF structure positive or zero then the program must
▪ Ex 5: determine if it’s a
▪ Word problem on selection Write a selection structure that assigns heritage- year. NB: take
structures a bonus to the sngBonus variable. The a heritage year as a year
bonus is determined by the which is divisible by 5.
salesperson’s code (intCode) and, in
some cases, by the sales amount
(sngSales). If the code is 1 and the
salesperson sold at least $10,000, then
the bonus is $500; otherwise these
salespeople receive $200. If the code is
2 and the salesperson sold at least
$20,000, then the bonus is $600;
otherwise these salespeople receive
$550. All others receive $150.

1
TIME/Date TOPIC/SUB TOPIC EXAMPLES/NOTES Extension work
Day 1 Iteration/Loops Ex 6: A program to determine the 4. Write a program to
▪ For Loop factorial of a number. determine the ten terms
▪ while Loop of the Fibonacci series
▪ Practical application of Ex 7: A program to determine the 5. A program to search
looping structures multiplication table for a grade 3 for a number in an array
learner. The program must allow for listing and return the
the input of an integer and display a location of the number.
table basing on that integer. For example, on the
following array:
23, 45, 12, 67, the
program must search for
12 and return location 3.
End of Day 1

End of Day 2
Day 2 Arrays Ex 8: Ten athletes lined up at the 6. Write a program that
20/05/2023 starting point at an international accept 100 student
1-D Arrays athletics tournament. When the names and marks
starting bell was rung, the other through an array. The
director of the competition signalled a program must determine
false start. Some athletes had the highest, lowest and
completed odd distances eg 7 meters average marks and
while others had completed even display them.
distances eg 8 meters. Others had not
moved an inch while some had moved
going backwards to cover a negative
distance. Write a program that
prompts the director to input the
distances covered by each of the ten
athletes. The program must determine
if each of the distance covered is even,
odd, zero or negative. The program
must display the totals of odd, even,
zero and negative distances moved by
the athletes.
Functions and Procedures Ex 9: Create a function for a number 7. Write a recursive long
▪ Procedures guessing game. The function should division function. The
▪ Functions allow the input of an integer as a guess program should accept
▪ Practical application of and compare it with a random number two parameters x and y
applications and that it generates. If the numbers and then display the
procedures match, then a congratulations message result of x/y
▪ Recursion must be shown. The user is given three 8. Create a function that
times to make a correct guess. can be used by banking
Ex 10: Write a recursive factorial personnel to calculate
function. Test your program using n = interest. The application
4. must not allow
borrowing if the interest
is more than 10% of the
principal.

2
TIME/Day TOPIC/SUB TOPIC EXAMPLES Extension work
Day 2 Object Oriented Ex 11: Create the students class 9. Create a class called
Programming template and instantiate it. car. A car had attributes,
▪ Class templates make, engine size, engine
▪ Inheritance number and date of
▪ Polymorphism manufacturing. Engine
▪ Encapsulation number is set by the
▪ Abstraction constructor. Create the
methods of the class.
Create a car called
Tayota that inherits the
features of the base class
Examination Tips
End of Tutorial

You might also like