Create a function-numweeks


Discuss the following:

Q: Create a function called numWeeks that takes an integer parameter representing a number of days and returns an integer that is the number of whole weeks in that number of days. For example, if the parameter was 25, the function would return 3, because there are three whole weeks in 25 days. If the parameter is 0 or negative, the function should return 0; you should check for this with an if statement.

Solution Preview :

Prepared by a verified Expert
Visual Basic Programming: Create a function-numweeks
Reference No:- TGS01938666

Now Priced at $25 (50% Discount)

Recommended (94%)

Rated (4.6/5)