---
# System prepended metadata

title: Untitled

---

#作業3
***判斷是否為7的倍數**
```
1.程式碼:
t=input('請輸入0~1000之間的數字')
num= int(t)
while num<0 or num > 1000
    print ('try again')
    t= input('請輸入0~1000之間的數字')
    num= int(t)
       if num.isdigit():
           print('正整數')
           if  num % 7 == 0:
              print(num, '是7的倍數')
           else:
              print(num, '不是7的倍數')
```


2. 執行結果:
![](https://i.imgur.com/KCmYtMC.png)



