Rewrite the following statements including the while-stateme…

Rewrite the following statements including the while-statement so it does the same calculation but uses only a for-statement: no while-statements are allowed: sum=0num = 1000while num > 500:   if num % 5 == 0:       sum = sum + num   num = num – 2  

Define a Python function check_sum (a, b, c) with three int…

Define a Python function check_sum (a, b, c) with three int arguments a, b, c. When called passing specific values for a, b, and c, your function should return True when the sum of any two of the three passed arguments is equal to the third argument.  Otherwise, your function should return False. For example, check_sum (1,2,3) should return True, since 1+2==3. check_sum (1,1,1) should return False, since 1+1 != 1.