Fastest Way to Learn DSA in Java | Full Roadmap
Summary
TLDRHarshit Trehan shares his journey of learning Data Structures and Algorithms (DSA) in Java, starting from his college days. Despite studying C++ in high school, he found Java to be easier for DSA due to its lack of pointers and automatic memory management, which helped reduce errors and debugging time. Harshit walks through his learning process, from mastering Java basics to tackling advanced data structures like trees and graphs. He emphasizes the importance of practicing through platforms like Pep Coding, Interview Bit, and LeetCode, eventually securing internship offers from top companies. His story offers valuable insights for anyone looking to master DSA in Java.
Takeaways
- 😀 Harshit Trehan, a Software Engineer at Atlassian, shares his journey of learning DSA (Data Structures and Algorithms) and transitioning from C++ to Java.
- 😀 He initially studied C++ in high school, but switched to Java for DSA due to its simpler memory management and absence of pointers.
- 😀 One of the key reasons for switching to Java was its automatic garbage collection and the absence of pointers, which reduced errors and debugging time.
- 😀 Harshit found Java to be beneficial for DSA as it simplified syntax and eliminated the common mistakes associated with pointer management in C++.
- 😀 He spent a week learning Java basics using resources like Java T Point, covering key concepts such as data types, variable declaration, and object-oriented programming.
- 😀 After getting comfortable with Java, Harshit started learning DSA, starting with basic data structures like Arrays, Strings, and Linked Lists.
- 😀 He practiced coding in Java by following Pep Coding’s YouTube playlist, which helped him learn DSA concepts in the language.
- 😀 Harshit continued his DSA learning by solving problems on platforms like Interview Bit and Lead Code, focusing on both basic and advanced data structures.
- 😀 He recommends solving the Lead Code Top 150 Interview Questions list, which provides important problems that have been asked in real interviews.
- 😀 To stay sharp for interviews, Harshit participated in coding contests on Lead Code, improving his ability to solve problems under time constraints.
- 😀 By the third year, Harshit had solved over 150 DSA problems, leading to multiple internship and placement offers, including from companies like Atlassian, TCS, and Infosys.
Q & A
Why did Harshit Trehan switch from C++ to Java for learning DSA?
-Harshit switched from C++ to Java because Java doesn't use pointers, reducing the chances of errors and making coding easier. Additionally, Java handles memory management automatically, which saved him time and effort, especially when learning DSA.
What challenges did Harshit face while learning DSA in C++?
-Harshit faced difficulties with pointer-based memory management in C++, which often led to silly mistakes that were hard to debug. This frustration with debugging and managing memory manually pushed him to switch to Java.
What resources did Harshit use to learn Java basics?
-Harshit used the JavaTpoint website to learn Java basics, which provided in-depth tutorials on Java's syntax, data types, variables, and object-oriented programming concepts like classes, inheritance, and polymorphism.
How did Harshit improve his DSA skills in Java?
-Harshit followed Pep Coding's YouTube playlist, which explained data structures and related problems while coding in Java. This helped him learn DSA concepts without struggling with Java syntax. He practiced coding in Java consistently until he became comfortable with it.
Which data structures did Harshit focus on during his DSA learning journey?
-Harshit started with arrays and strings, then moved on to linked lists, stacks, queues, and hash maps. After mastering these, he tackled advanced data structures like trees, graphs, and dynamic programming.
How did Harshit practice DSA problems after learning the basics?
-Harshit practiced DSA problems on InterviewBit, which provided important questions for each data structure. He solved them in Java, building his understanding and coding skills. He also used LeetCode to work on interview-level questions.
What did Harshit do to prepare for coding interviews?
-Harshit prepared for coding interviews by solving the Top 150 Interview Questions list on LeetCode. These questions were frequently asked in interviews, and he used Java to solve them. He also checked LeetCode's discussion tab for optimized solutions when he faced difficulties.
How did Harshit stay in touch with DSA during his placement preparation?
-Harshit participated in weekly and bi-weekly coding contests on LeetCode. These contests helped him practice solving problems under time constraints, which was useful for his online coding rounds and interviews.
Which companies offered Harshit an internship or job?
-Harshit received internship offers and job offers from companies like Atlassian, Infosys, TCS, and more after completing his DSA preparation.
What advice did Harshit give to others learning DSA in Java?
-Harshit advises learners to start by mastering Java basics before diving into DSA. He also recommends using resources like Pep Coding for DSA in Java, InterviewBit for problem practice, and LeetCode for interview prep and contests. Consistent practice and participation in coding contests are key to improving problem-solving skills.
Outlines

This section is available to paid users only. Please upgrade to access this part.
Upgrade NowMindmap

This section is available to paid users only. Please upgrade to access this part.
Upgrade NowKeywords

This section is available to paid users only. Please upgrade to access this part.
Upgrade NowHighlights

This section is available to paid users only. Please upgrade to access this part.
Upgrade NowTranscripts

This section is available to paid users only. Please upgrade to access this part.
Upgrade NowBrowse More Related Video

How to Learn DSA in 6 Months | Full Roadmap

Is DSA worth it in 2024?

How to make Projects for Internship & Placement from Scratch | Atlassian, Juspay, BNY Mellon, TCS

1.2+ Lakhs Stipend 🔥| How he cracked 𝐆𝐨𝐨𝐠𝐥𝐞 Internship from Tier 2-3 college

90 Days DSA Roadmap ! 🔥 | DSA Conquered! 💯 | Beginner to Advanced Level!

DSA with Java The FASTEST Way to Get Ahead in 2024
5.0 / 5 (0 votes)