A. EhAb AnD gCd

滴答滴答--题目链接 

A. EhAb AnD gCd

time limit per test

1 second

memory limit per test

256 megabytes

input

standard input

output

standard output

You are given a positive integer xx. Find any such 22 positive integers aa and bb such that GCD(a,b)+LCM(a,b)=xGCD(a,b)+LCM(a,b)=x.

As a reminder, GCD(a,b)GCD(a,b) is the greatest integer that divides both aa and bb. Similarly, LCM(a,b)LCM(a,b) is the smallest integer such that both aa and bb divide it.

It's guaranteed that the solution always exists. If there are several such pairs (a,b)(a,b), you can output any of them.

Input

The first line contains a s

猜你喜欢

转载自blog.csdn.net/chen_zan_yu_/article/details/104911151
gcd