Logo 庄博文的博客

博客

666

2023-04-02 16:32:05 By 庄博文

………………666,我只有6

神秘报错,大神帮帮我

2023-03-30 18:17:53 By 庄博文

我好像在报错的同时进入了C++的头文件库!!! 在一天我写程序的时候,日常语法报错,可是在我查看报错的时候,突然点进了一个数据库,应该是头文件库,粘贴出来给大家看看: // C++ includes used for precompiling -- C++ --

// Copyright (C) 2003-2013 Free Software Foundation, Inc. // // This file is part of the GNU ISO C++ Library. This library is free // software; you can redistribute it and/or modify it under the // terms of the GNU General Public License as published by the // Free Software Foundation; either version 3, or (at your option) // any later version.

// This library is distributed in the hope that it will be useful, // but WITHOUT ANY WARRANTY; without even the implied warranty of // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the // GNU General Public License for more details.

// Under Section 7 of GPL version 3, you are granted additional // permissions described in the GCC Runtime Library Exception, version // 3.1, as published by the Free Software Foundation.

// You should have received a copy of the GNU General Public License and // a copy of the GCC Runtime Library Exception along with this program; // see the files COPYING3 and COPYING.RUNTIME respectively. If not, see

/// http://www.gnu.org/licenses/. * @file stdc++.h This is an implementation file for a precompiled header. */

// 17.4.1.2 Headers

然后下面就是一堆头文件,有C的,有C++的!!!非常全面,基本上都有了!!!!!!

哪位大神知道啥意思啊??? 源程序如下:

include

//必须要用万能头文件!!!!!!!!!

#define N 1000005
#define ll long long
using namespace std;

int a[N],n;
int m,max;

int maxf(int x, int y){return x>y?x:y;}

bool check(int x)
{
    int s = 0;
    for (int i = 1; i <= n; i++)
    {
        s+=maxf(a[i] - x,0);
        if (s >= m) return true;
    }
    return false;
}

int main()
{
    scanf("%d%lld", &n, &m);
    for (int i = 1; i <= n; i++)
    {
        scanf("%d", &a[i]);
        if (a[i] > max) 
        max = a[i];
    }
    int l=0,r=max;
    int ans = 0;
    while (l < r)
    {
        int mid = (l + r) / 2;
        if (check(mid))
        {
            l = mid + 1;
            ans = mid;
        }
        else r = mid;
    }
    printf("%d", ans);
}
//end
除了前三条报错以外,其他的报错点击进去,都能进入一个新世界!!!
大佬帮我看看咋回事????
@xushuoxin

#9999 来自庄博文的疑问(必看)探秘helloworld网站系列之《第一位提交者》

2023-03-30 18:01:26 By 庄博文

大家快看看,helloworld提交记录达到121839条了,哪位大神告诉我提交记录#1,是谁提交的啊,在提交记录第几页啊???

1示意:

ID 题目 提交者 结果······(后面省略,反正不重要)

10 #15在屏幕上输出hi 未知 100······

9 #15在屏幕上输出hi 未知 100······

8 #15在屏幕上输出hi 未知 100······

7 #15在屏幕上输出hi 未知 100······

6 #15在屏幕上输出hi 未知 100······

5 #15在屏幕上输出hi 未知 100······

4 #15在屏幕上输出hi 未知 100······

3 #15在屏幕上输出hi 未知 100······

2 #15在屏幕上输出hi 未知 100······

1 #15在屏幕上输出hi 未知 100······

          页数???

ps:**(可能会出现#0的情况) 所以第一个提交的是谁???????在第几页???????评论区大神找到了给个链接,给个答案呗 :)*十分感谢!!!!!!!!!*

#114有惊喜,点进去,博客附链接,CZY是个海王!!!

2023-03-28 22:58:40 By 庄博文

4872求解!!!!!!!!!!!!!!

2023-03-19 17:03:54 By 庄博文
庄博文 Avatar