샘플 input 에 대해서는 값 다 나오는데..
--------------
#include <stdio.h>
int main(void) {
int T;
int test_case;
scanf("%d", &T);
for (test_case = 1; test_case <= T; test_case++) {
int n;
unsigned long long small = 2;
unsigned long long big = 1;
scanf("%d", &n);
for (int j = 1; j <= n; j++)
{
big = big * 2;
}
for (int k = 2; k <= n; k++)
{
if ((small - 1) % 3 == 0 && (small - 1) / 3 != 1 && ((small-1)/3 )%2==1)
{
small = (small - 1) / 3;
}
else
small = small * 2;
}
if (small>big)
{
unsigned long long temp = small;
small = big;
big = temp;
}
printf("Case #%d\n", test_case);
printf("%llu %llu\n", small, big);
}
return 0;
}
스몰 걍 알고리즘이 틀림
ㅇㅇ 알고리즘 자체가 틀림