Question: Please write the following program in Python 3. Please solve this question without using loops. Make sure the program output marches the sample run in

Please write the following program in Python 3. Please solve this question without using loops. Make sure the program output marches the sample run in the question illustrated in the image.

Please write the following program in Python 3. Please solve this question

without using loops. Make sure the program output marches the sample run

1.3 Question 2 (60 points) Write a python program that computes the zakat, obligatory charity, on sheep. The program asks the user to input the number of sheep, and then the zakat is calculated based on the following schedule: The number of sheep ranging Zakat Amount To 39 No zakat From 1 40 121 120 200 I sheep 2 sheep 3 sheep 201 399 400 499 4 sheep 500 599 5 sheep ... Same pattern as the last two rows Notes: Make sure that the input value is a positive integer. If not, the program must print the following message: "Wrong input. Number should be an integer greater than 0", and then terminate. Using loops in solving this question is not allowed. 1.3.1 Sample Runs Please enter the number of sheep: -3 Wrong input. Number should be an integer greater than 0 Please enter the number of sheep: 24 The zakat amount = 0 sheep Please enter the number of sheep: 119 The zakat amount = 1 sheep Please enter the number of sheep: 618 The zakat amount = 6 sheep

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!