description: Let's define S(x) to be the sum of digits of number x written in decimal system. For example, S(5) = 5, S(10) = 1, S(322) = 7.
  
  We will call an integer x interesting if S(x + 1) < S(x). In each test you will be given one integer n. Your task is to calculate the number of integers x such that 1 ≤ x ≤ n and x is interesting.
  
  Input
  
  The first line contains one integer t (1 ≤ t ≤ 1000) — number of test cases.
  
  Then t lines follow, the i-th line contains one integer n (1 ≤ n ≤ 10^9) for the i-th test case.
  
  Output
  
  Print t integers, the i-th should be the answer for the i-th test case.
  
  Example
  
  Input
  
  
  5
  1
  9
  10
  34
  880055535
  
  
  Output
  
  
  0
  1
  1
  3
  88005553
  
  Note
  
  The first interesting number is equal to 9.
solution: import static java.lang.Math.max;
  import static java.lang.Math.min;
  import static java.lang.Math.abs;
  import static java.lang.System.out;
  import java.util.*;
  import java.io.*;
  import java.math.*;
  import java.util.Map.*;
  public class A{
  	
  	public  static void main(String [] args)
  	{
  		FastReader sc = new FastReader();
  		int T = sc.nextInt();
  		mainLoop:
  		while(T-->0)
  		{
  			
  			int n = sc.nextInt();
  			int ans = n/10;
  			String s = n +"";
  			int temp = 0;
  			int temp2 = 0;
  			for(int i = 0;i<s.length();i++)
  			{
  				 temp += Integer.parseInt(s.charAt(i)+"");
  				
  			}
  			s = (n+1)+"";
  			for(int i = 0;i<s.length();i++)
  			{
  				 temp2 += Integer.parseInt(s.charAt(i)+"");
  				
  			}
  			if(temp2 < temp)
  				ans++;
  			System.out.println(ans);
  		}
  	}
  	static int countSetBits(int n)
  	{
  		int count = 0;
  		while (n>0){
  			count += n & 1;
  			n >>= 1;
  		}
  		return count;
  	}
  	public long gcd(long a,long b)
  	{
  	if(a == 0)
  		return 1;
  	return gcd(b%a,a);
  	}
  	
  	public long power(long x, int y)
  	{
          if (y == 0)
              return 1;
          else if (y % 2 == 0)
              return power(x, y / 2) * power(x, y / 2);
          else
              return x * power(x, y / 2) * power(x, y / 2);
  	}	
  
  	public static void sout(Object s){
  	
  	out.print(s);
  		
  	}
  
  
  }
  
  
  
  class Pair implements Comparable<Pair>
  {
  	int i;
  	int j;
  	
  	public Pair(int i, int j)
  	{
  		this.i = i;
  		this.j = j;
  	}
  	public int compareTo(Pair a)
  	{
  		if(a.i == this.i)
  			return 0;
  		else if(a.i > this.i)
  			return -1;
  		else
  			return 1;
  	}
  }
  
  
  class FastReader{ 
          BufferedReader br; 
          StringTokenizer st; 
          
          public FastReader() 
          { 
              br = new BufferedReader(new
              InputStreamReader(System.in)); 
          } 
    
          String next() 
          { 
              while (st == null || !st.hasMoreElements()) 
              { 
                  try
                  { 
                      st = new StringTokenizer(br.readLine()); 
                  } 
                  catch (IOException  e) 
                  { 
                      e.printStackTrace(); 
                  } 
              } 
              return st.nextToken(); 
          } 
    
          int nextInt() 
          { 
              return Integer.parseInt(next()); 
          } 
    
          long nextLong() 
          { 
              return Long.parseLong(next()); 
          } 
    
          double nextDouble() 
          { 
              return Double.parseDouble(next()); 
          } 
    
          String nextLine() 
          { 
              String str = ""; 
              try
              { 
                  str = br.readLine(); 
              } 
              catch (IOException e) 
              { 
                  e.printStackTrace(); 
              } 
              return str; 
          }
          public int [] readArr(int start,int n)
          {
  			int [] a = new int[n];
  			for(int i = start;i<n;i++)
  				a[i] = nextInt();
  			return a;
  		}
          public long [] readArrLong(int start,int n)
          {
  			long [] a = new long[n];
  			for(int i = start;i<n;i++)
  				a[i] = nextLong();
  			return a;
  		}
  		public static void sort(int[] arr)
  		{
  
          ArrayList<Integer> ls = new ArrayList<Integer>();
          for(int x: arr)
              ls.add(x);
          Collections.sort(ls);
          for(int i=0; i < arr.length; i++)
              arr[i] = ls.get(i);
  		}
  		public void sort(long[] arr)
  		{
          ArrayList<Long> ls = new ArrayList<Long>();
          for(long x: arr)
              ls.add(x);
          Collections.sort(ls);
          for(int i=0; i < arr.length; i++)
              arr[i] = ls.get(i);
  		}
  		public  void print(int[] arr)
  		{
  			for(int x: arr)
  				out.print(x+" ");
  			out.println();
  		}
      } 
  
   
  