azhar556's blog

By azhar556, history, 5 years ago, In English

Hi, I just solved my first dfs problem 1020B - Badge. Honestly i've never solve dfs before and i was thinking very long to understand this, this is very new for me. Summary, dfs in this problem is basically searching the one who visited twice and then break, and repeat several times depend the "n". This is my submission 45184407, in my submission i was trying to separate my dfs function to make easier to debug this and to make easier to read. One thing make me confused on this problem is the sequence is starting with one(1). Usually i starting with zero(0), but in this case its hard to implementing because the array input is based with one(1) too. Then to make easy i starting with one(1).

(newbie 996)

Full text and comments »

  • Vote: I like it
  • 0
  • Vote: I do not like it

By azhar556, history, 5 years ago, In English

Hi, i am very tired because i'd just solving 788A - Functions again and i feel like "Oh, my God. This is too hard for me, but i have to solve it." This is "A" problem, but for Div.1 (i am still Div.2 and its like "C" problem in Div.2). And then i look to the other contestant code. I am very lazy at that time because i feel the problem is not for me, but no no... I continue to understanding how to solve the problem.

Back then i'd try my code, but its still "time limit exceeding". After hours of understand the other contestant code i feel like, yeah... its hard but i can do it. Several minutes later i try to submit my code and voila..! By the way, i am not copy the other contestant code, but i try to understand how to solve without "time limit" and i write with my own code.

I've doing this several times since i submit my first code 3 months ago. Yes, its look impossible. But if you can do it, its not impossible anymore.

Keep fight, Imad (newbie 996).

Full text and comments »

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