🧠 Day 20 Theme: Sorting & Frequency-Based Problem Solving Concepts Covered: Sorting techniques (Bubble, Selection, Insertion, Merge, Quick) Built-in sort functions in Java, Python, JavaScript Sorting arrays & lists of objects Pair logic using sorted order (two-pointer & binary search techniques) Frequency pairing after sorting (count, group, compare) 📚 Learn from These Resources 📘 Sorting in Java 👉 https://lnkd.in/gnbjPpUM 👉 https://lnkd.in/gXY8FVjm 📗 Sorting in Python 👉 https://lnkd.in/gk3s4T4y 👉 https://lnkd.in/ghGHcBgi 📙 Sorting in JavaScript 👉 https://lnkd.in/gT-dJVdY 👉 https://lnkd.in/gZmwYQRn #75DaysOfKnowledge #Sorting #AlgorithmDesign #LeetCode #ProblemSolving #Java #Python #JavaScript #CodingJourney
Gowtham R’s Post
More Relevant Posts
-
🧠 Day 11 of 75 Days of Knowledge Theme: Strings & Character Arrays — Java | Python | JavaScript Strings are how we represent text, names, and messages in code. They look simple — but they hide deep logic for manipulation, comparison, and pattern matching. Today’s focus: String creation, operations, and common interview problems. 💡 Concepts Covered String declaration and immutability String concatenation and interpolation Traversing strings using loops Common methods (length, substring, indexOf, replace, split, join) String comparison & character arrays Converting between strings and numbers 📚 Learn Strings in Each Language 📘 Python — Strings 👉 https://lnkd.in/gfwG6ztm 👉 https://lnkd.in/gSkGf3MG 📗 Java — Strings & StringBuilder 👉 https://lnkd.in/gFJwy5FK 👉 https://lnkd.in/g--34c7f 📙 JavaScript — Strings 👉 https://lnkd.in/gUWfvU4Z 👉 https://lnkd.in/gM-mRGNf 🧩 Try This Practice Idea Reverse a string manually (without built-ins) Count vowels and consonants Check if a string is palindrome Find frequency of each character 🧠 Practice Online → https://replit.com/~ #75DaysOfKnowledge #Strings #ProgrammingBasics #Java #Python #JavaScript #ProblemSolving #LeetCode #CodingJourney #LearningToCode
To view or add a comment, sign in
-
Day 8 – Strong Number (Factorial Sum of Digits) – Java & Python 💡 Problem: A number is called a Strong Number (or Factorion) if the sum of the factorial of its digits equals the number itself. Examples: 145 → 1! + 4! + 5! = 145 ✅ 2 → 2! = 2 ✅ 40585 → 4! + 0! + 5! + 8! + 5! = 40585 ✅ 123 → 1! + 2! + 3! = 9 ❌ 🧠 Approach: 1️⃣ Extract each digit of the number. 2️⃣ Find the factorial of that digit and add it to a running sum. 3️⃣ Compare the final sum with the original number. Optimization Tip: Precompute factorials of digits 0–9 once and reuse them — avoids repetitive calculations. Time Complexity: O(d) Space Complexity: O(1) where d = number of digits. our Turn: Did you know there are only four Strong Numbers (1, 2, 145, 40585) under 1 million? Try running the code and share your results 👇 #CodeWithTanseer #DSA #Java #Python #CodingChallenge #ProblemSolving #Numbers #MathInCode #SoftwareEngineer #BackendDeveloper #InterviewPrep #LogicalThinking #Factorial
To view or add a comment, sign in
-
-
Day 10 – Print a Half Pyramid Pattern (Java & Python) > 💡 Problem: Print a half-pyramid of stars (*) based on the number of rows. Example (n = 5): * ** *** **** ***** 🧠 Approach: 1️⃣ Use two nested loops — Outer loop → for each row Inner loop → for printing stars in that row 2️⃣ Print a newline after each row. Time Complexity: O(n²) Space Complexity: O(1) Your Turn: Can you modify this to print an inverted pyramid or a right-aligned one? Drop your version below 👇 #CodeWithTanseer #DSA #Java #Python #CodingChallenge #ProblemSolving #Patterns #LogicBuilding #SoftwareEngineer #BackendDeveloper #InterviewPrep
To view or add a comment, sign in
-
-
Day 15 – Find the Largest Element in an Array (Java & Python) 💡 Problem: Given an array of integers, find the largest element. Example: Input → [10, 25, 3, 99, 56, 77] Output → 99 🧠 Approach: 1️⃣ Initialize a variable max with the first element. 2️⃣ Traverse the array — If arr[i] > max, update max = arr[i]. 3️⃣ After one full pass, max holds the largest value. Time Complexity: O(n) Space Complexity: O(1) Your Turn: Can you modify this to find both minimum and maximum in a single traversal? (Hint: use two variables 😉) Drop your code below 👇 #CodeWithTanseer #DSA #Java #Python #CodingChallenge #ProblemSolving #Arrays #LogicBuilding #SoftwareEngineer #BackendDeveloper #InterviewPrep
To view or add a comment, sign in
-
-
Day 16 – Find the Second Largest Element in an Array (Java & Python) > 💡 Problem: Given an array of integers, find the second largest element. Example: Input → [10, 25, 3, 99, 56, 77] Output → 77 Approach – Single Pass (Optimized O(n)): Initialize two variables: first = second = -∞ Traverse the array: If current > first → update second = first, then first = current. Else if current > second and current != first → update second = current. One traversal, no sorting needed! Your Turn: Can you modify this to find both smallest and second smallest elements? Drop your version below 👇 #CodeWithTanseer #DSA #Java #Python #CodingChallenge #ProblemSolving #Arrays #Optimization #SoftwareEngineer #BackendDeveloper #InterviewPrep
To view or add a comment, sign in
-
-
🚀 Quick Experiment: Comparing Lines of Code Across Languages I recently did a small personal experiment to compare how many lines of code (LOC) are typically required to implement the same task in Python, Java, and C++. 📌 Assumption: Each new statement appears on its own line — no one-liners or compressed logic. Here are the results: 🐍 Python: 11 LOC ☕ Java: 36 LOC 💻 C++: 44 LOC Key Takeaways Python is very concise for implementing tasks. Java requires more structure and verbosity. C++ is the most verbose among the three. 💡 Note: This experiment considers Lines of Code only, not execution speed or efficiency. I’d love to hear your thoughts: Do you value code compactness over verbosity for readability and maintenance? Hashtags #Programming #Python #Java #CPlusPlus #CodeEfficiency #SoftwareDevelopment #CodingExperiment #DeveloperInsights #TechLearning #ProgrammingTips
To view or add a comment, sign in
-
Thought it would take an hour to replicate our TypeScript Transactional (OLTP) to Analytical (OLAP) story in python. A day of work for Olivia Kane and I later, we present our OLTP → OLAP workflow: but this time in #Python with #SQLModel instead of #Typescript. What TypeScript gave us “for free,” Python made us earn. The upside: ✅ deterministic ClickHouse tables ✅ safe CDC replay ✅ everything lives in Python The downside: ❌ more manual work because Python We’d love feedback from Python teams: would a SQLModel→Moose generator make your life easier, or is manual fine? Abdur-Rahmaan, what have you seen succeed here? I would love to see some Python best practices that mirror TS’s ability to work with types. Blog: https://lnkd.in/gq_AuJuT 🐙: https://lnkd.in/gj6QVUar
To view or add a comment, sign in
-
Johanan and Olivia from our product team have been stress-testing #MooseOLAP in TypeScript and Python this week, exploring sharing data models between upstream OLTP ORMs and MooseStack. The TypeScript version of this OLTP → OLAP pattern “just worked.” The Python version (SQLModel + Moose) didn’t get all the freebies from typescript’s types. This post shows how to land CDC-driven OLAP tables in ClickHouse without rewriting your app logic. Focus is on SQLModel. Read the full breakdown here → https://lnkd.in/gtqh63JN
Thought it would take an hour to replicate our TypeScript Transactional (OLTP) to Analytical (OLAP) story in python. A day of work for Olivia Kane and I later, we present our OLTP → OLAP workflow: but this time in #Python with #SQLModel instead of #Typescript. What TypeScript gave us “for free,” Python made us earn. The upside: ✅ deterministic ClickHouse tables ✅ safe CDC replay ✅ everything lives in Python The downside: ❌ more manual work because Python We’d love feedback from Python teams: would a SQLModel→Moose generator make your life easier, or is manual fine? Abdur-Rahmaan, what have you seen succeed here? I would love to see some Python best practices that mirror TS’s ability to work with types. Blog: https://lnkd.in/gq_AuJuT 🐙: https://lnkd.in/gj6QVUar
To view or add a comment, sign in
-
Local computer + ollama pull gpt-oss:20b Topic: Python Code -> C++ Code system_prompt = """ Your task is to convert Python code into high performance C++ code. Respond only with C++ code. Do not provide any explanation other than occasional comments. The C++ response needs to produce an identical output in the fastest possible time. """ def user_prompt_for(python): return f""" Port this Python code to C++ with the fastest possible implementation that produces identical output in the least time. The system information is: {system_info} Your response will be written to a file called main.cpp and then compiled and executed; the compilation command is: {compile_command} Respond only with C++ code. Python code to port: ```python {python} ``` """
To view or add a comment, sign in
-
Explore related topics
Explore content categories
- Career
- Productivity
- Finance
- Soft Skills & Emotional Intelligence
- Project Management
- Education
- Technology
- Leadership
- Ecommerce
- User Experience
- Recruitment & HR
- Customer Experience
- Real Estate
- Marketing
- Sales
- Retail & Merchandising
- Science
- Supply Chain Management
- Future Of Work
- Consulting
- Writing
- Economics
- Artificial Intelligence
- Employee Experience
- Workplace Trends
- Fundraising
- Networking
- Corporate Social Responsibility
- Negotiation
- Communication
- Engineering
- Hospitality & Tourism
- Business Strategy
- Change Management
- Organizational Culture
- Design
- Innovation
- Event Planning
- Training & Development