문제풀이:
#include <string>
#include <vector>
using namespace std;
int solution(int number, int n, int m) {
int answer = 0;
if(number%n==0 &&number%m==0)
return answer = 1;
else
return answer = 0;
}
'코딩테스트' 카테고리의 다른 글
프로그래머스_0단계_ 더 크게 합치기C++ (0) | 2024.04.09 |
---|---|
프로그래머스_0단계_ A 강조하기C++ (0) | 2024.04.09 |
프로그래머스_0단계_n 번째 원소부터 C++ (0) | 2024.04.09 |
프로그래머스_0단계_모음 제거 C++ (0) | 2024.04.09 |
프로그래머스_1단계_약수의 개수와 덧셈 C++ (1) | 2024.04.07 |