Блог пользователя __asm__

Автор __asm__, история, 2 года назад, По-английски

Crying took part in the last contest.

we can see at 01:53:17 Crying submitted problem C and get wa on test 3 : 175019412

and just after 1 minute, he submitted another code and get AC : 175019782

and the code is

__asm__(R"(
	.file	"C.cpp"
	.section	.text$_Z4Readv,"x"
	.linkonce discard
	.globl	_Z4Readv
	.def	_Z4Readv;	.scl	2;	.type	32;	.endef
	.seh_proc	_Z4Readv
_Z4Readv:
.
.
.
.

r1:
	.space 4
	.ident	"GCC: (tdm64-1) 4.9.2"
	.def	getchar;	.scl	2;	.type	32;	.endef
	.def	puts;	.scl	2;	.type	32;	.endef
 
)");

and after only 2 minutes, he submit D and get AC 175020241 and the code is also asm

how can he do all this in 3 minutes?

in code C we find .def getchar; .scl 2; .type 32; .endef .def puts; .scl 2; .type 32; .endef

but the previous submission use only cin/cout and should not contain this!

and the other contest we can find similar things happening : 174133908

  • Проголосовать: нравится
  • +108
  • Проголосовать: не нравится

»
2 года назад, # |
Rev. 2   Проголосовать: нравится -8 Проголосовать: не нравится

The only rule that can (ever possibly) be violated through the use of assembly, should be the one rule about obfuscation. But still, as long as Codeforces supports it in the language list, I do not think it will be a violation of the rule.

Also, how he did it: He simply compiled his C++ code into assembly with GCC (G++). About the getchar part, it either could be that he quickly swapped out the I/O part, or it could be just the internal implementation of cin. I think it's likely the latter, though.

EDIT: NVM, I REALIZED CF DOESN'T HAVE ASM IN THE OFFICIALLY SUPPORTED LANGUAGES.

  • »
    »
    2 года назад, # ^ |
      Проголосовать: нравится +26 Проголосовать: не нравится

    i try the previous one, they are completely different, and i don't think he can change I/O and fix code in 1 minute

    • »
      »
      »
      2 года назад, # ^ |
      Rev. 2   Проголосовать: нравится -27 Проголосовать: не нравится

      I don't think it would be totally impossible for him to do that.

      • »
        »
        »
        »
        2 года назад, # ^ |
          Проголосовать: нравится +24 Проголосовать: не нравится

        and how can he solve D in 2 minutes? it's impossible...

      • »
        »
        »
        »
        2 года назад, # ^ |
          Проголосовать: нравится +18 Проголосовать: не нравится

        The assembly version contains functions Init, Solve and Read; the C++ version only has solve. The C++ version contains vector<int> R,C while the assembly version has separate variables r1,c1,r2,c2,r3,c3.

        • »
          »
          »
          »
          »
          2 года назад, # ^ |
          Rev. 2   Проголосовать: нравится -31 Проголосовать: не нравится

          to LuchkinVyacheslav and __asm__: These wouldn't be a good reason to think that someone is cheating. He could have used 3 pairs of variables first, changed it for two vectors, and then back to variables. Same goes for I/O and the rest of the code. Also as a proof on how solving multiple problems in such a small time gap is possible — I present to you: tourist.

          • »
            »
            »
            »
            »
            »
            2 года назад, # ^ |
              Проголосовать: нравится 0 Проголосовать: не нравится

            D1==D2 so it's ok to solve D1 D2 at the same time;

            and code for A is just

              ios::sync_with_stdio(false);
              cin.tie(0);
              int tt;
              cin >> tt;
              while (tt--) {
                int n, k;
                cin >> n >> k;
                vector<int> a(n);
                vector<int> mx(k);
                for (int i = 0; i < n; i++) {
                  cin >> a[i];
                  mx[i % k] = max(mx[i % k], a[i]);
                }
                cout << accumulate(mx.begin(), mx.end(), 0LL) << '\n';
              }
            

            It's enough to solve it in 1minute for tourist.

            • »
              »
              »
              »
              »
              »
              »
              2 года назад, # ^ |
                Проголосовать: нравится -22 Проголосовать: не нравится

              I think you still did not get my point; How tourist did it and how Crying may have done it are essentially the same. They both just prepared the code locally and submitted multiple problems at once. An actual chad mindset, but you can't call that "cheating".

              • »
                »
                »
                »
                »
                »
                »
                »
                2 года назад, # ^ |
                  Проголосовать: нравится 0 Проголосовать: не нравится

                but he rebuild his whole code in 1 minute and the code is not short

                • »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  2 года назад, # ^ |
                    Проголосовать: нравится -20 Проголосовать: не нравится

                  I didn't think I need to explain anymore, but see, anything could have happened in the process of editing his code. As an example, he may have reformed his code once entirely, realized it would be easier the previous way, rolled it back with a f*** ton of Ctrl+Zs, and then got back to implementing.

              • »
                »
                »
                »
                »
                »
                »
                »
                2 года назад, # ^ |
                  Проголосовать: нравится +16 Проголосовать: не нравится

                Is Cring your wife ?

                • »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  »
                  2 года назад, # ^ |
                  Rev. 2   Проголосовать: нравится -21 Проголосовать: не нравится

                  Well, not really. But I do get pissed off about some false claims about someone cheating by an alt made only a few hours ago or less.

          • »
            »
            »
            »
            »
            »
            2 года назад, # ^ |
              Проголосовать: нравится 0 Проголосовать: не нравится

            i'll try to find code included Init, Solve, Read.

»
2 года назад, # |
  Проголосовать: нравится +2 Проголосовать: не нравится

The internet is very fucking interesting right?

»
2 года назад, # |
  Проголосовать: нравится +18 Проголосовать: не нравится

i love Mophie _ZMF_

»
2 года назад, # |
  Проголосовать: нравится +44 Проголосовать: не нравится

Enough, leave it.I can't believe such things of no importance also lead to criticism of Genshin Impact. Firstly, Genshin has never irritated you; secondly, it has never done anything intolerable, so what is wrong with you that you keep discrediting Genshin mindlessly? Mihoyo is dedicated to cultural exportation and Chinese propagation, however maniacs like you know nothing but tapping keyboards online, calumniating our great company of conscience. The bright future of Chinese indigenous electronic games will definitely be devastated by people like you

  • »
    »
    2 года назад, # ^ |
      Проголосовать: нравится +30 Проголосовать: не нравится

    I almost got a fart and I have to turn to Yuanshen for big things. First, Yuanshen didn’t invite you to provoke you, and secondly, he didn’t do anything that hurts the world. What happened to you has kept you brainless and smeared. Mihayou spends every day trying his best to promote the cultural output. Chinese culture, a troll like you will only slander conscience companies by typing on the keyboard online, the future of Chinese games will be ruined by people like you

  • »
    »
    2 года назад, # ^ |
      Проголосовать: нравится +29 Проголосовать: не нравится

    It's hard for me to imagine why a player with a normal mental state would make the choice of "not playing Genshin Impact". Genshin Impact's astonishing combat mechanism and rather impressive plot design can be said to be the best among all the games in the current game circle, and none of them. Friends who do not play Genshin Impact not only lose the game experience, but also a basic game understanding and spiritual belief. Genshin Impact could obviously use the game world to bring everyone to a whole new level of life, but you gave up. For the rest of your life, you will fall into the icy abyss and experience hopeless regret and a sense of decline.

»
2 года назад, # |
Rev. 2   Проголосовать: нравится +14 Проголосовать: не нравится

May all the suffering souls of the world be subordinated to ja ran, under the holy light of Diana.

ja men!

»
2 года назад, # |
  Проголосовать: нравится +43 Проголосовать: не нравится

Clearly, it is obfuscation. Please, don't abuse the rules.

  • »
    »
    2 года назад, # ^ |
      Проголосовать: нравится +33 Проголосовать: не нравится

    First time I've seen your recent response to cheating bloggers.

    wow.

  • »
    »
    2 года назад, # ^ |
    Rev. 2   Проголосовать: нравится -37 Проголосовать: не нравится

    Just realized that assembly is not an officially supported language by codeforces. Given this, I support your decision for skipping the submission. Thanks for the quick response!