Please help me with memset() and fill()

Revision en2, by NguyenDangQuan, 2020-04-24 18:59:15

Hi, I'm now crazing with memset() and fill() or fill_n(), in the Problem D Div3 Round #636, i used fill_n() and it was TLE, so I changed to memset() and accepted. I dont't understand the way memset work. Can you explain me ? Thank you

*In addition, sometimes i use memset but it doesn't work well Here are my submissions: TLE: https://codeforces.me/contest/1343/submission/77570494 Accepted: https://codeforces.me/contest/1343/submission/77570825

History

 
 
 
 
Revisions
 
 
  Rev. Lang. By When Δ Comment
en2 English NguyenDangQuan 2020-04-24 18:59:15 159
en1 English NguyenDangQuan 2020-04-24 18:45:39 338 Initial revision (published)