Divisible by 5 or not-1
Submissions: 1467   Accuracy:

22.96%

  Difficulty: Easy   Marks: 2

The problem is to check whether the decimal representation of a given binary number is divisible by 5 or not.

Input:
First line consists of T test cases. Only line of every test case consists of Binary string.

Output:
Print "Yes" if it is divisible by 5, else "No" (without quotes).

Constraints:
1<=T<=100
1<=|length of binary string|<=100

Example:
Input:

2
1010
10000101001
Output:
Yes
Yes

** For More Input/Output Examples Use 'Expected Output' option **

Contributor: Saksham Raj Seth
Author: saksham seth


If you have purchased any course from GeeksforGeeks then please ask your doubt on course discussion forum. You will get quick replies from GFG Moderators there.



Need help with your code? Please use ide.geeksforgeeks.org, generate link and share the link here.

to report an issue on this page.