Ups & Downs in CDC Journey!

Shivansh Shukla
18 min readDec 19, 2022

--

Hello everyone, I am Shivansh Shukla, a 3rd year undergraduate from the Department of Computer Science and Engineering, enrolled in its B.Tech course. I will be interning at Graviton Research Capital in the summer of 2023. This blog includes my CP background, preparation strategy and experience in CDC coding rounds & interviews. I have been a huge follower of this CDC-blog series by CodeClub & I’ll try to include all minor helpful details regarding CDC internship drive at KGP, so yeah, this is going to be quite long!

BACKGROUND

I was introduced to the world of Competitive Programming in Jan 2021 through the Intro to CP seminar by CodeClub. After a couple of weeks, GOC & CodeClub jointly started a CP workshop for all divisions. I started my CP journey through its div3 workshop: attending live classes, solving problems given at the end of session and making notes of suggestions provided by seniors [Link of recordings of the sessions]. After getting familiar with STL basics, I started participating in regular contests in CodeChef and Codeforces. I wasn’t very consistent and rarely upsolved the questions or checked editorials. As a result of which, my CF rating just floated in the 1200–1400 range till June. Also, post the CP workshop, I didn’t learn new topics like DP, Graphs, trees thinking that they are too hard for me now, so my performance was just based on SpeedForces and luck without any actual progress!

Takeaway— Make sure to upsolve at least one problem more than what you could solve during the contest otherwise you’re practically not making any significant progress despite the rating changes . Also, check out editorial & discuss with friends to get to know about alternate approaches for a problem. Furthermore, you are never too immature to learn new topics if you have covered its prerequisites (if any) and also without learning new algorithms/ data structures, how do you expect to make progress in CP?

Due to covid, our 1st year just wrapped up in around 6–7 months & our summer vacation was also reduced to mere 4 weeks. So, it was extremely difficult for a fresher like me to manage various things. Also, I feel this is one of the major reasons why there are very less number of high rated coders in 2020 batch as compared to senior batches.

In summer vacation, I started up with the basics of Dynamic Programming. My legendary friend Anubhav suggested a few standard problems covering various tactics of DP to start up with. I mainly read articles & solved problems from GFG. After that, my 3rd semester started in which Algorithms 1 course introduced me to almost all essential data structures & algorithms like Graphs, DP, Binary Tree, DSU, Heaps, etc. I tried to practice standard problems on GFG side by side with the theory getting covered in classes. As I am CR of CSE 2020 BTech batch, so I was much involved in #Boycott_Online_classes & #Reopen_KGP activities that time & due to some other reasons, again I wasn’t that much consistent with CP, but this time as I was equipped with the knowledge of essential DSA, my CF rating was floating in the range 1400–1550.

After my 3rd semester, I started CP again with full zeal and determination. I came across Kartik Aroras youtube channel & I strongly recommend everyone struggling with Dynamic Programming to follow his playlist thoroughly. I followed it sincerely & completed CSES DP section problems & after that, I started with DP on tree through his another playlist. Meanwhile, through the GOC CP Mentor-Mentee Program, I got helpful suggestions from my mentors, Debajyoti Dasgupta & Udaya Bhaskar Cheepurupalli which indeed boosted my confidence. I also used to pick random problems of 1600–1700 CF range & tried solving them. Finally, I hit Expert in CF on 18th Dec & 5-star in CodeChef on 24th Dec. After that, my 4th semester & the worst phase in my KGP life started. I neither did CP properly nor paid attention in Acads and just wasted time . Till my 3rd semester, I had a decent CG of 9.6 & then I got a SG of 8.67 in my 4th semester which reduced my CG significantly. I also lost my loving grandmother, with whom I was most attached, which broke me from inside;(

EXHAUSTIVE CDC PREPARATION

After the 4th semester ended, I sat down to decide what all I had to do to make this vacation as productive as possible & to secure an internship from one of the best companies of Day 1 :

  • CP — Most of CodeClub & GOC seniors who were in dual degree(& were having their CDC along with me) were 1800+ on CF & as CP is essential for clearing coding rounds for Day 1–2 companies, I decided to devote a major chunk of my daily time to CP and made sure to participate in all regular contests on CF/CC. I set a target to hit Candidate Master in CF & 6-star in CC by the end of vacation.
  • CV — I had done no internships or projects under profs, so yeah my CV was blank except few CP achievements in Facebook HackerCup, Google Kickstart, CodeJam, Hashcode etc. I had little knowledge of Web Development earlier & had done a project in the Software Engineering Laboratory [ which was a team project & my contribution wasn’t that much]. Therefore, I had to learn essential WebD to understand my own project first XD and to design one more as most seniors suggested to have at least 2 projects in CV.
  • DSA — YES you need to devote separate time to DSA even if you are good in CP, as most seniors suggested and I agree also! Topics like Linked List, Binary tree, etc are rarely used in CP but are very essential for CDC. I practised from Interview Bit only though I suggest everyone to practice from LeetCode & GFG also if you’ve enough time. I tried to cover most questions of all essential topics and bookmarked the questions which I found worth solving again.
  • OOPS — If you’re a Btech student, then OOPS & language fundamentals are the only core CS topics you need to prepare for CDC. I studied OOPS mainly from the slides of the Software Engineering course by Prof PPD & GFG. If you’re not from the CS department, then ask for the slides from your friend in the CS dept or feel free to reach out to me :)
  • Prob-Stats & Quant Puzzles — To be honest, I made a lot of plans regarding this but due to lack of time in July, I had to skip quant preparation. As a result of which, I didn’t apply for a quant role in any company later on [except of course Jane Street XD]. Most people suggest Heard on the street, 50 Challenging Problems in Probability and Brainstellar for quant preparation, which one can follow!

I started participating in CF from my alt account [shuklaji1102] & this time made sure to upsolve the questions & look at editorials as much as possible. I also started solving A2OJ div2D ladder & covered around 30 problems there. Meanwhile, I learnt Segment Tree from cp-algorithms.com and practiced problems in the CF-Edu section. After this, I spent the complete month of May on DP covering Simple DP, DP on trees, DP with bitmasking, Digit DP — first watching the respective Kartik Arora’s playlist & then solving problems mentioned in various CF blogs. I also solved & highly recommend everyone to completely solve all problems of AtCoder Educational DP round [link] — it covers almost all types of DP problems which you would be encountering at least till reaching purple in CF. After this extensive practice, DP & tree became my strongest topics and I was even able to solve 2200–2300 rated CF problems sometimes during the contests. Besides, I participated in all GOC-CDC series contests and it helped me a lot to understand the type and difficulty of questions asked in coding rounds of last year.

Afterwards, I hit 6-star in CodeChef[shivansh1102] & Candidate Master in CF in the first half of June. Then, I started with Graphs — one of my weakest topics that time — through Algozenith videos. Graphs’ subtopics are covered very decently there & slowly my fear for graphs started to reduce. I was preparing for CDC considering that everything would be offline and would start in the month of August, but around the end of June, we were informed that coding rounds were going to start from mid-July and CV building would start after 4–5 days. I hurriedly started on an interesting project with my friend Likhith & we were able to finish it before the CV deadline. I strongly recommend everyone to request at least 2–3 seniors for reviewing CV as it is an important factor in CDC. I hurriedly learnt & practiced other topics like Game theory, Trie, Number theory, Probability, String Algorithms, etc and read OOPS concepts & other C++ fundamentals. Also, I solved a few GOC-CDC series contests of previous years to prepare exclusively for coding rounds.

CODING ROUNDS

Coding rounds for Day 1 and Day 2 companies started from 15th July. We had 2–3 tests daily on an average along with PPTs of various companies, so yeah it was very hectic. Before each test, I used to go through several blogs of this CDC-blog series by CodeClub, searching for count of ques, topics, shortlisting criteria and any other info concerned with that particular company which might be useful. Usually people just write about only those companies in which they got shortlisted, which creates difficulty in searching for some particular company. So, I decided that I’ll try to include all helpful minor details of various companies despite whether I got shortlisted or not & here it is :

Uber : Test platform — CodeSignal, 4 ques to be solved in 90 min. First one was very easy implementation based, 2nd one was greedy with around 1200–1300 CF difficulty, 3rd one based on greedy/binary search around 1600 CF difficulty [I got to know later that this ques was directly taken from CF]. Last ques was a nice tree problem but it had a random test case generator which was faulty, so it was giving segfault for everyone. I solved the first 3 problems in around 50 min and got a partial score in 4th. I wasn’t shortlisted.

DE Shaw : Test platform — HackerRank, 3 ques — individually timed [25+35+35 min] — Only sample cases were given & verdict of hidden test cases was not visible :| Q1 was on stack around 1200–1300 CF difficulty, Q2 was on dfs, greedy around 1600–1700 CF difficulty and last one was good ques around 1800 CF. I solved the first 2 ques and couldn’t solve the 3rd one & didn’t get shortlisted.

Quantbox : Test platform — HackerRank, 2 coding ques(60 min) followed by 14 MCQs(15 min) based on heavy OOPS. First coding ques was approximate type problem & 2nd one was an observation based hard problem. I passed 2/4 test cases in the first, 23/36 test cases in the 2nd and solved 8–9 MCQs. I didn’t get shortlisted.

Jane Street(Trader Profile) : Initially, CV submission was open to all departments. After this, they released a shortlist consisting of 30 names based on JEE rank, CGPA, olympiad achievements. Few were directly called for a zoom interview while few including me were given a hackerrank test link. I hadn’t prepared anything for the quant role, so I just gave the test for getting experience & fun. There were 5 subjective questions based on a central theme asking for expectations, probability and testing analytical & betting skills. I answered 3 out of them & didn’t proceed for further rounds as expected :)

Salesforce : Test platform — HackerRank, 3 ques to be solved in 100 min. 1st one was on game theory around 1200–1300 CF. 2nd one was on greedy, STL (some legends even use segment tree XD) around 1400–1500 CF. 3rd ques was an easy implementation type question around 1300 CF. I was able to solve all of them.

Oracle : There were no coding questions. All were MCQs based on Reasoning, English, binary search tree & AVL tree.

Rubrik : Test platform — HackerRank, 4 nice ques to be solved in 90 min. I was able to solve just 2 questions & was feeling very low after this test, so I don’t remember topics of questions. Please refer to other blogs for it.

Microsoft : Test platform — Codility, 2 easy standard questions to be solved in 2 hours. Many people solved both in around 10–15 minutes as expected. I couldn’t find anyone who was able to identify the logic behind shortlisting criteria — it wasn’t CG, CP ratings, dept, time taken to solve problem, CV. Again, I wasn’t shortlisted.

By this time, I had almost given up ;( Nothing was going according to the way I thought. Then, I analyzed what I had done in the last 15–20 days & came to the conclusion that this is probably due to the fact that I hadn’t participated in any recent CF round, nor solved problems randomly in a timed manner. After this, I started giving virtual CF div3 rounds, mainly focussing on the last 3 problems & also practiced good problems from the Kickstart archive.

Graviton (Software) : Test platform — HackerEarth, 2 good problems to be solved in 75 min. First one was a nice shortest path problem involving Edge Space Reduction by constructing Pseudo nodes. Luckily, I have watched an easy problem based on this technique in one of AZ videos. Second problem was easy-medium based on number theory & sieve. I submitted both problems 32 minutes before the end of the test. They shortlisted 10–12 people who solved both problems.

Sprinklr : Test platform — HackerEarth, 3 problems to be solved in 90 min. First two were adhocish implementation based questions while third one was a very nice dp on tree problem involving use of number theory around 1800–2000 CF rating difficulty. I submitted all the questions 35 min before the end of the test. People who solved the first 2 ques completely and 3rd one partially were shortlisted.

Intuit : Test platform : Glider, 4 ques to be solved in 90 minutes. Q1 & Q3 were easy adhoc problems around 1000 CF difficulty, Q2 was a good question on dp on bitmasking around 1600–1800 CF difficulty, Q4 was also a nice question on dp on tree around 1700–1900 CF difficulty. I was able to solve all the questions within time.

Goldman Sachs : Test platform — HackerRank, there were 4 sections individually timed. First one had 2 hard coding questions to be solved in 30 min, 2nd section had MCQs based on JEE math covering ellipse, matrices, probability, etc. 3rd section had 2 behavioural essay type questions, while 4th section had MCQs based on core CS topics. All MCQs were having negative marking. I read first coding ques wrongly & wasted 15 min in that, later on, did some shit & couldn’t solve any of them :( I solved around 70–80% MCQs of section 2, wrote something in section 3 & attempted a few questions of section 4 as most of them were based on Networks, OS, etc which most btech people aren’t aware of. I couldn’t find the exact weightage of each section for shortlisting and as expected, I wasn’t shortlisted.

NK Securities (Software) : Test platform : HackerRank, 2 coding questions + 10 MCQs having negative marking to be solved in 100 minutes. One coding question was based on dp on tree (exactly same as one of last day’s APT quant test question as I got to know later). 2nd coding question was a good problem which I was able to solve only partially. I also solved a few MCQs which were mostly based on OOPS. I wasn’t expecting it but I got shortlisted.

Google : Test platform : HackerEarth. This test was common to several IITs, BITS and a few other colleges. We were given a window of 4 hours in which we can start at any time, hence, as one can expect, questions were floating from one college to other XD. There was a set of 5 questions of different difficulty out of which any 2 questions were given randomly to be solved in 60 minutes. One question was a modified knapsack dp problem, one was based on string trie, one was a good question on bitmasking (I have solved the exact same ques during GOC-CDC series) while one was a very nice problem based on meet in the middle technique. Unfortunately, I got this meet in the middle question which I couldn’t solve & just passed 5/10 test cases and passed all test cases in other problem. I had heard from the seniors that Google pays much attention to Kickstart ranks(under 300 preferred) and considers it more than online assessment. I had two under 300 Kickstart ranks, still I didn’t get shortlisted :(

Nutanix : Test platform : HackerRank, 2 questions to be solved in 75 min. Topics were dp and tree. I solved one question completely and the other one partially. I wasn’t expecting a shortlist but they shortlisted almost everyone who solved one ques fully and one partially. Also, it was strange to see their shortlist which had around 30 people but only from CS.

After this, we were provided with a slot of 4–5 days to return to campus. During this period, I mainly focused on OOPS, reading previous year blogs of this series, giving mock interviews with my friends Likhith and Gaurav, reading implementation of STL containers like vectors, etc. Honestly, I had planned a lot of other things which I couldn’t do that time and finally reached campus a bit demotivated and exhausted. On 29th July, we started getting shortlists of various companies, it was a very painful experience not finding your roll no in them & seeing other people with quite less CP ratings getting shortlisted. During those days, I realized the importance of having a good CG, my CG was a little decent (9.37) but not enough to grab a shortlist specially in those companies which had CV-shortlisting. Finally on 30th July, I went through my CV and prepared a bit for HR rounds. After this around 11 pm, I received a call from placecoms asking for my preference order. I was in constant touch with my mother who was continuously motivating me despite herself being very low. I was instructed by placecom to mark my attendance in whatsapp groups at 5 am. I tried but couldn’t sleep till around 3:30 am with hell lot of things coming in mind.

31st July — The Day 1!

I woke up at 5 am, was roaming here & there talking with my mother, when I received a g-meet link from placecom at 5:50 am and was informed that my interview will start at 5:55 am. I hurriedly changed my cloth, touch feet of my parents on video call & sat for interview :

The interview begins:

Two young guys joined the meet (they were 2022 graduates as I got to know later), told their names and asked me for my introduction. After this, I was given a medium-hard question containing N strings, a function f(x,y) defined over two strings and was asked to find something related to that. I repeated the question to the interviewer & asked a few questions to make sure that I understood the question well. Just after that, I gave a solution using trie & explained it thoroughly, deriving time & space complexities. Then they asked me if I could do it using some alternative approach & asked to use hashing. I was just saying all possible thoughts which were coming in my mind, amongst them I said “If we store the frequency of each prefix of string in a hashmap, then it would have worse complexities, so maybe if I do something else….”. He stopped me & asked to explain the approach which I just told. After this, both seemed highly satisfied though there were no improvements in time & space complexities XD.

Takeaway : Think LOUD! Keep telling each & every thing which comes to your mind, even when you’re not sure whether it is correct or not!

After this, I was given a hard question in which I had to suggest data structures to design a restaurant management system which can optimize the given 3 kinds of queries. I started by proposing a solution using C++ STL set, where each query will take O(logN). Then I stated time complexities for all things which came in my mind — queue, stack, map, priority_queue. After a few minutes, I proposed a nice solution using vectors & unordered_map which could handle all kind of queries in O(1) :)) Initially, he didn’t get my approach & asked me to dry run on a given input. Then I asked him to provide a doc or something else so that I can explain in a better manner(Yes! Till now it was just like a video call XD They didn’t even ask me to share screen). Finally, he was satisfied. After this, they asked me what courses I have covered and if I am comfortable with OS/Networks/COA to which I replied that they’ll be covered in later semesters. Then they asked me a few questions on OOPS, difference between int * const ptr and const int * ptr, stack & heap memory, core C++ questions, etc. This was followed by an easy-medium matrix question based on binary exponentiation which I answered quickly.

It was around 6:50am by that time, then they asked me if I had some other firm’s interview scheduled at 7 am. I checked whatsapp and found a NK Securities’ interview from 7 am. Then they asked me about my preference & started asking standard HR type questions. I was asked about my CP experience and he was noting down whatever achievements I was telling. Then, he asked me to wait for a few minutes, after which their HR joined & gave me an offer!!!!!! Finally, I called my parents and sister & gave them happy news after a long time :)

Final Points :

  • CP is the most important skill required to grab an internship through CDC in Day 1–2 companies. The difficulty of problems in coding rounds is increasing year by year. Apart from regular contests on Codeforces, CodeChef & Atcoder, do participate in competitions like ICPC, CodeJam, Kickstart, HashCode, HackerCup, SnackDown, etc. Mentioning good ranks in these contests give a huge boost to one’s CV.
  • After analysing coding rounds of Day 1–2 companies, I personally believe that they are neither much DSAish, like the ones in LeetCode nor much Adhocish, like the one in CF. I found them most similar to Kickstart rounds, where the hardest problem breaks down into a nice algorithmic problem involving DP, graphs, trees. Therefore, I strongly recommend everyone to practice through the Kickstart archive[link].
  • CGPA is another most important thing for CDC. I wasn’t shortlisted for several companies just because of CGPA despite having good CP ratings. Companies like Quadeye & Glean directly shortlisted people by CGPA this year. Hence, make sure to have a good CGPA!
  • Luck also plays an important role during the CDC process. I know people with 1700–1800 CF rating & not getting an offer on Day 1 and I also know people with not much preparation & around 1200 CF rating, still getting offers from decent Day 1 companies :)
  • It’s never too late! Around late mid June when we got to know that Day 1 would be on 31st July, I received a message asking about the timeline of phase-2 of the CDC process. I replied to him that it would be around Nov-Dec but not very good companies come in phase-2, and motivated him to prepare for phase-1 with full energy & enthusiasm. Also, I suggested to him some materials, blogs, tips to follow. On the night of 31st July, I again received a message that he got an offer in a nice Day 1 company!
  • The thing about which people prefer not to talk publicly — Gender. Yes, it’s true that some companies focus on diversity hiring & set different shortlisting criteria for males and females. So if you are a male candidate, accept it & prepare accordingly. However if you are a female candidate, you still have to do a lot of hard work as there’s a lot of competition even within girls. Though it is sad that people often forget this hard work & give one’s success credit to her gender :(
  • During the last phase of CDC preparation, Likhith & I have written short notes (kind of points to remember) for the slides by Prof PPD. One can go through them for preparation of OOPS [link]. It contains almost everything you might need to know for interviews & MCQs in shortlisting rounds.
  • Some points regarding Coding Rounds : Make sure you choose the language you want to code in at the beginning itself. Few platforms don’t allow copy-paste & your entire hard work may go waste. Also, try completing all problems as early as possible as many companies consider time of submission while shortlisting candidates. Do read the instructions very carefully and understand the policy of switching between various sections. If you can’t think of a complete solution or you’re not sure about your complete solution & running out of time, prefer submitting a brute force solution first with an aim to pass as many test cases as possible.

Acknowledgement

First of all, I would like to thank almighty God for showering his blessings on me. The CDC process was full of ups and downs and I had seen my friends struggling till 4–5 pm & still not getting offers, while I was summer-sorted by 7 am. Then I would like to thank my parents and sister for always believing in me and motivating me throughout the entire process. Also, I am beyond grateful to my seniors especially Rajat Bachhawat, Sahil Jindal, Udaya Bhaskar Cheepurupalli, and Debajyoti Dasgupta for their guidance and support.

A huge thanks to Vivek Gupta for helping me in achieving great heights in Competitive Programming starting from my very first semester. I wasn’t enrolled in AlgoZenith but he always answered my queries and gave great advice. Then, I would like to thank my friend Likhith for being my companion before and during the entire CDC process. Also, I would like to thank my pro friend Anubhav for helping me to improve my CP skills throughout the KGP life!

Hope this will help you in grabbing an internship offer in your dream company! Feel free to reach out to me through LinkedIn or Messenger in case of any queries.

ALL THE BEST!

--

--