Taha1506's blog

By Taha1506, history, 4 years ago, In English

Is it considered A cheating if I use another person's implemention for a data structure instead of designing one by myself?

  • Vote: I like it
  • +36
  • Vote: I do not like it

»
4 years ago, # |
  Vote: I like it +132 Vote: I do not like it

It depends on platform rules but usually you can use prewritten code if it is either written by you or was published on the internet with appropriate license (which allows you to use it) before the start of the contest. Obviously, you can't ask someone to implement a data structure for you during the contest.

»
4 years ago, # |
Rev. 2   Vote: I like it -14 Vote: I do not like it

.

  • »
    »
    4 years ago, # ^ |
      Vote: I like it +13 Vote: I do not like it

    Do u remember discovering Segment Trees on your own when you were stuck on some range query problem?

    Jon Louis Bentley : Yes

    • »
      »
      »
      4 years ago, # ^ |
        Vote: I like it +6 Vote: I do not like it

      That's not segment tree lol, wikipedia has wrong data structure under its definition

  • »
    »
    4 years ago, # ^ |
      Vote: I like it +63 Vote: I do not like it

    You'd be amazed at how often something like segment tree was actually discovered independently by newbie contestants :) .

    • »
      »
      »
      4 years ago, # ^ |
        Vote: I like it +22 Vote: I do not like it

      Been there, done that.

      Granted my implementation was very rudimentary and based primarily on guesswork, but yeah I did kinda discovered before I read up on it a few days later.

      • »
        »
        »
        »
        4 years ago, # ^ |
          Vote: I like it +10 Vote: I do not like it

        Yeah, fun times.

        Mine was using 2x less memory, like Fenwick, but the code was longer than segtree and Fenwick combined.

»
4 years ago, # |
  Vote: I like it 0 Vote: I do not like it

What about using someone else's library ? , it counts as open-source and prewritten

  • »
    »
    4 years ago, # ^ |
      Vote: I like it +1 Vote: I do not like it

    It's fine. Lots of people copy from KACTL for example.