title: Limiting user input on c++
body: <p>so, here's my code</p>
  
  <pre><code>#include &lt;iostream&gt;
  #include&lt;math.h&gt;
  using namespace std;
  int main()
  
  
      int T, N;
      int i = 1;
      int y = 5;
      cin &gt;&gt; T;
  
          while (T-- ) {
              cin &gt;&gt; N;
  
                  int c = pow(N, y);
                  int z = (c + 1) / (N + 1);
  
                  cout &lt;&lt; "Kasus #" &lt;&lt; i++ &lt;&lt; ": " &lt;&lt; z &lt;&lt; endl;
  
  
          }
  }
  </code></pre>
  
  <p>all i want to do is limiting the user input ( T and N), T is between 1 and 10, N is between 1 and 100000, how can i do that?</p>