Skip to content

Instantly share code, notes, and snippets.

@godtaehee
Created January 17, 2019 02:06
Show Gist options
  • Save godtaehee/b889e626dc5c58dfc4af50cda3d42688 to your computer and use it in GitHub Desktop.
Save godtaehee/b889e626dc5c58dfc4af50cda3d42688 to your computer and use it in GitHub Desktop.
C++
#include <iostream>
using namespace std;
int main(){
cin.tie(NULL);
ios_base::sync_with_stdio(false);
int N;
int X;
cin >> N >> X;
int a[N];
for(int i = 0; i < N; i++)
cin >> a[i];
for(int i = 0; i < N; i++){
if(a[i] < X)
cout << a[i] << ' ';
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment