Skip to content

Instantly share code, notes, and snippets.

@Baekjoon
Created May 17, 2015 12:16
Show Gist options
  • Save Baekjoon/5fbb9b4eb605ad3e07d4 to your computer and use it in GitHub Desktop.
Save Baekjoon/5fbb9b4eb605ad3e07d4 to your computer and use it in GitHub Desktop.
3.cpp
#include <iostream>
using namespace std;
int main() {
int a, b, c;
cin >> a >> b >> c;
if (a == b && b == c) { // AND
cout << "세 수가 같음";
} else {
cout << "안 같음";
}
if (a == b || b == c) { /* OR */
cout << "a가 b와 같을 수도 있고, b가 c랑 같을 수도 있음";
}
if (a == b || b == c) {
} else {
}
if (a != b && b != c) {
}
if (!(a == b)) { // NOT
}
return 0;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment