끄적끄적 코딩
article thumbnail
Published 2019. 9. 27. 14:48
[C++] 백준 2914번 저작권 알고리즘

n과 m을 입력받고 n * (m - 1) + 1을 출력해줍니다.

 

#include <iostream>
using namespace std;

int main(int argc, char* argv[])
{
	int n, m;

	cin >> n >> m;

	cout << n * (m - 1) + 1<< endl;

	return 0;
}

검색 태그