Lab Report#4.docx

  • Uploaded by: muhammad hussam
  • 0
  • 0
  • May 2020
  • PDF

This document was uploaded by user and they confirmed that they have the permission to share it. If you are author or own the copyright of this book, please report to us by using this DMCA report form. Report DMCA


Overview

Download & View Lab Report#4.docx as PDF for free.

More details

  • Words: 211
  • Pages: 4
AB REPORT#

TASK:

NTRODUCTION: A switch condition/statement allows a variable to be tested for equality against a list of values. Each value is called a case, and the variable the entered variable is checked for each case. To make a variable being checked, for only a single case and then stop the process if the case is true we use a function called

When the break statement is encountered inside a loop, the loop is immediately terminated and program control resumes at the next statement. Secondly we used another function in this program called,

In computer programming, a Default parameter (also called an optional parameter) is a function that has a default value provided to it. If the user does not supply a value for this parameter, the default value will be used.

The following screenshot shows the build-up of the program:

Switch Break Default Are the functions which are used in this program and they are defined in the introduction of the report.

The result that we got on the console window can be seen in the screenshot below:

SULT#2 (This result shows that if we enter a value that is not defined so the “default” will perform its function and Invalid grade will be printed out on the screen)

Related Documents

Lab
May 2020 22
Lab
June 2020 19
Lab
April 2020 14
Lab
July 2020 11
Lab
October 2019 51
Lab
May 2020 32

More Documents from ""

Lab Report#4.docx
May 2020 15
Lab Report#4.docx
May 2020 9
Lecture 4.pdf
December 2019 16
December 2019 13