fork download
  1. /*
  2.  * nerdyninja
  3.  * Omkar Prabhu <omkar.prabhu15@siesgst.ac.in>
  4.  */
  5. #include <bits/stdc++.h>
  6.  
  7. using namespace std;
  8.  
  9. int main()
  10. {
  11. // freopen("in", "r", stdin);
  12. // freopen("out", "w", stdout);
  13. ios_base::sync_with_stdio(0);
  14. // Start Solution here
  15. int t;
  16. cin >> t;
  17. while (t--) {
  18. int n;
  19. cin >> n;
  20. int a[n];
  21. for (int i = 0; i < n; i++) cin >> a[i];
  22. for (int i = 0; i < n; i++) {
  23. if (a[i]%10 != 7) printf("%d ", a[i]);
  24. }
  25. printf("\n");
  26. }
  27. // End Solution here
  28. cerr << "Solved in " << clock() << " ms" << endl;
  29. return 0;
  30. }
Runtime error #stdin #stdout 0s 4328KB
stdin
Standard input is empty
stdout