Computer Science, asked by RCBabeena, 1 day ago

write a qbasic program to check whether the number is divisible by 3 but not by 7​

Answers

Answered by madhulatapandey316
0

Answer:

10 INPUT NUMBER

20 IF NUMBER/3 = INT(NUMBER/3) AND NUMBER/7 = INT(NUMBER/7) PRINT “DIVISIBLE BY 3 AND 7”:GOTO 40

30 PRINT “NOT DIVISIBLE BY 3 AND 7”

40 END

This one is to check whether it is exactly divisible by both 3 and 7. If you want to check if it is exactly divisible by either 3 or 7 or both, just replace AND by OR in line 20 and change the PRINT statements accordingly.

Answered by 123diwakaryadav99
0

Explanation:

oadvxivdcidvduebfvdiebdiwboe feiebf

Attachments:
Similar questions