【奇文共赏3.0】 啸皱痨屎再度预言,亲自出马押题CSP J!,看周鲁冥师成功率如何!

· · 休闲·娱乐

有什么最新消息或者缺失欢迎私信,我尽力更新awa

可能夹带私货qwq

\colorbox{skyblue}{\color{purple}\large\text{【上集回顾】}}周鲁冥师出马押题,成功率达100%!

这次的奇闻来自于@CRZCQH,感谢Ta的投稿awa

\colorbox{pink}{\color{purple}\large\text{【相关话题】}}周 鲁 冥 师 同 道 中 人

\colorbox{yellow}{\color{red}\huge\textbf{【本期看点】}}\newline\color{orange}\textbf{周鲁冥师来押题2023 J组复赛了!!!}

小周老师的果然名不虚传!

我们来看这个T1的AC代码:

#include<bits/stdc++.h>
using namespace std;
typedef long long LL;
LL N = 114514;
int main()
{
    freopen("apple.in","r",stdin);
    freopen("apple.out","w",stdout);
    cin >> N;
    if( N == 0 )
    {
        printf("0 0");
        return 0;
    }
    LL temp = N,ans = 0;
    while( temp != 0 ){
        temp = ( temp << 1 ) / 3;
        ans++;
    }
    cout<<ans;
    ans = 1;
    while( ( N - 1 ) % 3 != 0 )
    {
        N -= ( N % 3 == 0 ? N / 3 : N / 3 + 1 );
        ans++;
    }
    cout<<ans;
    return 0;
}
//符 合 周 礼 QWQ

读文件?开头就有!你就说有没有吧!

数据类型?如果你不小心用short int,那么你就只会获得50分,就是要考你数据类型的表示范围!

你就说short int会不会错吧!

还有,这题要输入数字,就是要考你用intlong long这些装数字的类型,就是要看看有没有人用char

你就说有没有数据类型吧!

循环?中间俩大大的while没看见吗?你就说有没有循环吧!

数据结构?你们看见那大大的LL N;吗?你就说是不是装数据的吧!

\colorbox{black}{\color{white}\text{下 集 精 彩 继 续}}啸咒牢屎のCSP-S题解!