import java.io.*; import java.util.*; import java.text.*; import java.math.*; import java.util.regex.*; public class Solution { public static void main(String args[]){ Scanner sys=new Scanner (System.in); int tc=sys.nextInt(); for(int i=0;i 0){ //n = temp % 10; // sum = sum + n; // temp = temp / 10; // } if(sum%3==0) System.out.println("Yes"); else System.out.println("No"); } } }