fork download
  1. var tc,i,inp:longint;
  2.  
  3. function result(n:longint):int64;
  4. begin
  5. result:= ((n+4)*(n+3)*(n+2)*(n+1)) div 24;
  6. end;
  7.  
  8. begin
  9. readln(tc);
  10. for i:=1 to tc do
  11. begin
  12. readln(inp);
  13. writeln(result(inp));
  14. end;
  15. end.
Success #stdin #stdout 0.01s 252KB
stdin
2
2
1
stdout
15
5