Move python question files to 'questions' directory Move output files to 'outputs' directory Copy output files to 'questions' for ease of viewing Signed-off-by: Neil <neil@willofsteel.me>
14 lines
338 B
Plaintext
14 lines
338 B
Plaintext
Question 04:
|
|
Write a Python program to compute simple interest for a given principal amount, time, and rate of interest.
|
|
|
|
Answer:
|
|
def main(principal: int, time: int, rate: float) -> None:
|
|
print(f"Simple Interest: {principal * rate * time / 100}")
|
|
|
|
if __name__ == '__main__':
|
|
main(10000, 10, 5.0)
|
|
|
|
|
|
Output:
|
|
Simple Interest: 5000.0
|