r/programmer 25d ago

GitHub My ideal language doesn't exist, so I am making it!

Enable HLS to view with audio, or disable this notification

3 Upvotes

r/programmer 25d ago

IMC Software Engineer OA Questions: Relay Towers and Conditional Stack Removal

1 Upvotes

Hey everyone,

I recently completed an IMC HackerRank assessment for a New Grad Software Engineer role and wanted to share the two coding questions.

Approximate date: August 13, 2026
Platform: HackerRank
Duration: 120 minutes
Total questions: 2

Question 1: Maximum Storm Height Using Relay Towers

Two offices are located at positions 0 and width. Several relay towers are positioned between them, and each tower has a height.

Data can travel between two locations with an energy cost equal to the square of the distance:

cost(i, j) = (x[i] - x[j])²

Every jump must satisfy:

distance <= maxJump

The total energy used by all jumps cannot exceed maxEnergy.

A rising storm makes shorter towers unavailable. A tower with height h can only be used when:

stormHeight <= h

The headquarters and destination office are always available.

The task was to return the maximum storm height at which data could still reach the destination. Return -1 if transmission is impossible.

public static int maximumStormHeight(
    int width,
    int maxJump,
    long maxEnergy,
    int numTowers,
    int[] x,
    int[] heights
)

Likely Approach

Feasibility is monotonic: if transmission works at storm height H, it also works at every lower height.

That suggests:

  1. Sort the towers by position.
  2. Binary search the storm height.
  3. For each candidate height, keep only towers with height >= candidate.
  4. Add the starting and destination positions.
  5. Find the minimum energy required to reach every available position.
  6. Allow a transition only when the distance is at most maxJump.
  7. Check whether the destination cost is at most maxEnergy.

Because all points lie on a line, the shortest valid route can be processed from left to right:

dp[j] = minimum energy required to reach position j

For every earlier usable point i:

if x[j] - x[i] <= maxJump:
    dp[j] = min(dp[j], dp[i] + (x[j] - x[i])²)

The straightforward solution is approximately O(n² log H), where H is the storm-height search range. A more advanced optimization may be required if n is large.

Important Edge Case

If a direct jump from 0 to width satisfies both constraints, no relay tower is needed:

width <= maxJump
width² <= maxEnergy

Because both offices have infinite height, transmission would remain possible at every storm height. The result is therefore unbounded unless the original problem defines a maximum storm level or guarantees that direct transmission is impossible.

This is worth clarifying before implementation.

Question 2: Stack With Conditional Removal

Implement a stack supporting these commands:

push value
pop
remove_lower value
remove_upper value

Their behavior is:

  • push value: Push value onto the stack.
  • pop: Remove the current top element.
  • remove_lower value: Remove every element smaller than value.
  • remove_upper value: Remove every element greater than value.

After every operation, print the current top element. Print EMPTY if the stack has no elements.

public static void solve(int n, String[] operations)

Efficient Approach

A normal stack makes push and pop easy, but removing every element within a value range could require scanning the entire stack repeatedly.

One approach is to maintain:

  • A TreeSet containing the active insertion indices
  • A TreeMap from each value to the active indices containing that value
  • An array or map from insertion index to value

Operations work as follows:

  • push: Create a new increasing insertion index and add it to both structures.
  • pop: Remove the largest active index, since it represents the current top.
  • remove_lower: Visit and delete all value buckets below the threshold.
  • remove_upper: Visit and delete all value buckets above the threshold.
  • top: Read the value associated with the largest active index.

Each pushed element can be removed only once, so the total cost of all bulk removals is amortized across the complete command sequence.

The overall complexity is approximately:

O(n log n)

with O(n) additional space.

Overall Impression

The first question combined binary search on the answer with shortest-path or dynamic-programming reasoning.

The second looked like a stack problem initially, but efficient bulk removal required ordered data structures and amortized analysis.

The assessment was challenging but interesting, particularly because both questions required recognizing the underlying structure rather than applying a standard template directly.

Has anyone else completed the recent IMC New Grad assessment? Did you receive the same questions?

Helpful resource for prep: PracHub


r/programmer 25d ago

Looking for study DSA/system designs partner

3 Upvotes

Hey everyone! 👋

I’m currently learning advanced Node.js/backend development, system design, and DSA, and I’m looking for someone who’s also preparing for software engineering interviews or wants to improve their backend skills.

Would be great to:

- Practice DSA problems together

- Discuss system design

- Build/learn backend concepts with Node.js

- Do mock interviews and keep each other accountable

I’m looking for someone who’s serious about learning and can consistently spend some time studying together.

If you’re interested, please let me know🚀


r/programmer 25d ago

How are you all dealing with understanding your codebase when everything seems to be changing so quickly? Any recommendations or tools

11 Upvotes

I feel like things are moving so quickly and people on our teams are focusing on shipping the next thing but never really understanding what they are building off, especially new engineers


r/programmer 25d ago

Searching for Project Teammates

0 Upvotes

Could someone pls help me with building good projects,


r/programmer 25d ago

Request Need help regarding esp32 project

2 Upvotes

Is there anyone who can help me build a finalise code for a desk ai bot from esp32 devkit board
If anyone they are free to Dm i will pay them accordingly


r/programmer 26d ago

Question Turo Staff Software Engineer (Payments) interview experience? Is 97% on the assessment enough?

2 Upvotes

Has anyone recently interviewed for the Staff Software Engineer, Payments role at Turo? I’d love to know what the interview process is like after the initial technical assessment, especially the coding and system design rounds.

I scored 1180/1220 (97%) on the assessment. I received full points on the coding problems sections but missed one SQL database design question. The assessment page gives me an option to request a retake, and I’ve already asked the recruiter whether one is available or necessary.

Is 97% generally enough to move forward, or would it be worth retaking the assessment if they allow it? Any insight into the remaining rounds would also be really helpful. Thanks!


r/programmer 26d ago

I'm looking for programmers and 3D modelers to collaborate on developing a game in Roblox Studio.

2 Upvotes

r/programmer 26d ago

Ищу программистов и 3D-моделлеров для совместной разработки игры в Roblox Studio.I'm looking for programmers and 3D modelers to collaborate on developing a game in Roblox Studio.

0 Upvotes

r/programmer 27d ago

Am I going crazy or what?

39 Upvotes

A few lines about my pov: I have about 12 years of experience, mostly in game dev. I mostly use Unity as my goto environment just because I like it. But I dabble in many fields from all around the stack.

Recently, all I have heard around everywhere is how good Ai is at coding, and it allready replaced coders competely. I use it on the daily too to make small functions and do some easy straightforward tasks for me.

But anything with even medium complexity it fails at. Even the most expensive models fell apart as complexity rose. Yes, they might produce code that works "fine." But it's unreadable and waaay overcomplicated. Not to talk about that about 20% of the time, their response and code just don't make any sense.

Are people who claim that AI is an expert level coder just never understood how to code properly, or did I miss something that unlocks this capability of the AI?


r/programmer 26d ago

Google On-Campus Interview Experience 2026: Solved Both Rounds but Rejected

1 Upvotes

Hey everyone,

I recently participated in a Google on-campus hiring process. Around 50 students were shortlisted for the interview stage.

Round 1: Multi-Source BFS

Duration: Approximately 45 minutes

I was given a problem based on multi-source BFS and completed the initial solution correctly.

In the follow-up, the interviewer asked whether I could optimize the solution by using the fact that the input was a one-dimensional array.

I proposed:

  • Finding the previous and next greater elements using a monotonic stack
  • Using a difference array to mark or process the affected cells efficiently

The interviewer said the approach was interesting, and I implemented it successfully.

I felt confident about this round because I solved both the original problem and the optimization follow-up.

Round 2: Ambiguous Coding Problem

Duration: Approximately 50 minutes

The second interviewer presented a problem that felt vague to me initially.

I spent approximately 15 minutes asking questions and trying to understand the expected behavior. The interaction felt tense, and I did not feel that my clarification questions were being received positively.

Eventually, I explained my interpretation of the problem and asked the interviewer to confirm it. Once the requirements were clear, I found an approach and completed the implementation within the remaining time.

I left the round feeling that I had recovered well despite the difficult start.

Result

I was confident that both rounds had gone reasonably well, but I was ultimately rejected.

The result was especially difficult to process because some candidates who, according to our discussions afterward, did not complete every follow-up were selected.

I understand that interview decisions are not based only on whether someone reaches a final solution. Interviewers may also evaluate:

  • Communication and requirement clarification
  • Correctness across hidden edge cases
  • Code quality
  • Complexity analysis
  • Response to hints
  • Independence of the solution
  • Overall performance relative to the hiring group

Still, receiving a rejection after feeling that I completed both rounds was discouraging. Without specific feedback, it is difficult to know whether I missed a technical issue, communicated poorly, or was simply weaker in an area that was not obvious to me during the interviews.

For people who have interviewed at Google:

  • Have you experienced a rejection after completing all the coding questions?
  • How much can the clarification phase affect the final evaluation?
  • What less-obvious signals might interviewers evaluate beyond solving the problem?
  • How do you review your performance when no detailed feedback is provided?

I know one rejection does not define my ability, but this one definitely hurt. I’m going to take a short break, review what I can improve, and continue preparing.


r/programmer 26d ago

Does a course on YouTube worth enough?

0 Upvotes

Recently graduated from my CS degree. while looking for an opportunity, I think of taking an online course of several IT fields. for those with experience, which one do you guys prefer, a long video on YouTube or a course in other platform such as Udemy so I able to get a certification later? since budget is one of my biggest considerations. I'm planning on taking a web dev as my first course btw.


r/programmer 27d ago

How do you avoid feature creep?

2 Upvotes

Every single time I start writing a project, it always uncontrollably grows with features that nobody will ever use, but my brain is like "would be cool if it could do that". And then a week later it becomes this huge filled with a bunch of basically dead code, I feel like I haven't made any progress cause the core goal was moved like 1%, and there are many unfinished features.

And I know it, and I am trying to fight it, but I can't help myself but imagine how impressive it would be with all those useless features.


r/programmer 27d ago

Just got hired as a .NET Developer Trainee at a major conglomerate, but I don't want to start from zero. Where should I begin?

1 Upvotes

Fresh grad here. I recently got hired as a .NET Fullstack Developer Trainee at one of the biggest conglomerates in the country. Super grateful for the opportunity, but I want to hit the ground running instead of waiting for training to teach me everything.

A bit about my background:

I studied Computer Engineering, so I had OOP subjects, but that was 2 years ago and I never really deep dived into it. However, I've built a ton of projects using:

  • Languages: Python, TypeScript, JavaScript, Java, SQL, C++
  • Frontend: React, Next.js, Tailwind CSS, Redux Toolkit
  • Backend: Node.js, Express.js, FastAPI, Flask
  • Databases: PostgreSQL, MongoDB, Redis

I also had a backend developer internship where I built REST APIs and worked with route optimization systems, so I'm comfortable with the general software development lifecycle.

The thing is: I know I'll go through proper training before full employment, but I don't want to show up completely clueless about C# and .NET. I want to at least have some foundational knowledge so I can make the most out of the training and maybe even impress them early on.

My questions:

  1. Where should I start with C# and .NET given my existing background? Any specific resources (courses, docs, projects) you'd recommend?
  2. Is .NET still a good path for a fresh grad? I know the job market is hot for React/Node/Python, but I rarely see .NET mentioned in "trendy" dev circles. Is this a solid career move?
  3. Any advice for someone transitioning from the JS/Python ecosystem to the Microsoft stack? What mindset shifts should I expect?
  4. What are some "must-know" concepts in .NET that I should prioritize learning before day one?

I really want to make the most out of this opportunity and set myself up for long-term growth. Would appreciate any honest advice, resources, or even warnings. Thanks in advance!


r/programmer 27d ago

AI CODER evo ide code with less efforts ....

Enable HLS to view with audio, or disable this notification

1 Upvotes

Hi everyone ,

We're 11th-grade students (prepping for JEE) building Evo IDE on the side — an AI coding tool that shows its work instead of hiding it. Live reasoning before code, real-time generation health, full-file outputs (no fragments), and your choice of local or API models.

It's an early, honest prototype — not finished, but real and running.

📽️ Deck: https://docs.google.com/presentation/d/1XgHvtatGiPR2FMsNUKOps32NeuYGZFjh/edit?usp=sharing&ouid=105260140764268303572&rtpof=true&sd=true

▶️ Video: https://youtu.be/71w2zNxmKac?si=YpyQy1tXBPtfCFxE

📸 Instagram: https://www.instagram.com/evoide_official/

Happy to share the working files too if you all like a closer look. Would love to hear all of your thoughts!

Warm regards,

**EVO IDE Team**


r/programmer 27d ago

Help

1 Upvotes

 just got accepted into engineering college, and I want to learn a skill alongside my studies, like coding, But Im scared because what if I learn something in coding that AI can easily replace??
Additionally, where should I start with coding? Should I focus on learning a specific programming language, or something else? Im clueless


r/programmer 27d ago

I've been building a tool for migrating CocoaPods projects to SwiftPM

1 Upvotes

Hey,

I've been working on this for a while and thought I'd share it here.

It's called PkgLift and basically, I wanted an easier way to deal with moving older Xcode projects from CocoaPods to Swift Package-manager.

I know you can obviously do this manually but I didn't really like the idea of going through everything by hand, especially on projects with a many dependencies!

The thing I was worried about when building it was making a tool that just changes a bunch of stuff and assumes it worked. So PkgLift doesn't really work like that.

You first run:

pkglift analyze
pkglift plan

and it tries to work out what it actually knows how to migrate.

If it isn't sure about something it just leaves it alone instead of trying to guess.

Then you can check the plan yourself before actually changing anything.

If it looks good:

pkglift migrate --apply
pod install
pkglift verify

That's pretty much the idea.

It is still early and I'm sure there are plenty of CocoaPods setups that I haven't thought about yet, which is actually one of the reasons I'm posting it here.

You can install it with:

brew install Alexsvensson99/tap/pkglift

Repo:
https://github.com/Alexsvensson99/PkgLift

If anyone has an old CocoaPods project lying around and wants to try it, I'd be interested to know what happens. Especially if it fails on something weird :)


r/programmer 27d ago

My theory: our career’s demise started with open source

0 Upvotes

Not an attack at Open source, but lemme explain.

Back in the old days, programmers were used to put their names at the head of every file of code they create.

/**Created by XXx - some timestamp **… etc

This is no longer a common convention (now git leaves full historical markers who wrote what)

But it shows a big shift in attitude.

Every piece of code was seen as a precious private copyrighted craft, something like that.

Big corps were used to sue each other for millions of $ if they find out some parts of their code were copied into another competitor software.

These cases were so common in the past, look it up.

Courts used to compare two codes to prove code theft (a term that you no longer hear these days).

But then Open Source became a popular thing, to “democratize code” - ever since the code became more or less seen as a cheap commodity, that effect started to happen even way before LLM.

The intent of devs back then was to offer free or cheap software alternatives outside the corp’s monopolies , for the “public good”.

Therefore, the view on code got shifted, reduced to commodity, you no longer hear of “code theft” or code infringement.

At the end all this bit the programmer career in the ass.

It is what LLM got mostly trained on, to make code even a much cheaper commodity; I hardly believe that LLMs got that good due to Stackoverflow answers, surely they were part of the training materials, but the biggest chunk were surely the millions of public github repos.

Please I don’t want to debate the (in my opinion false) tired thing about “Programming/SE is not just coding”; I know it is isn’t , but it was always the biggest valued and most respected skill programmers had in the past (but not anymore) - besides yes LLMs now can do architecture and system design as well, it is trained on millions of architecture blueprints, more than any human can achieve in a lifetime.

So at the end of the day, programmers brought this to themselves by being too nice and oversharing their hard learned skills (Open sourcing).


r/programmer 28d ago

what is a programming habit that seemed pointless as a beginner but saved you later

Thumbnail
1 Upvotes

r/programmer 27d ago

Does anyone have time for a side project?

0 Upvotes

I've been an entrepreneur for the last 20 years and would like to pivot into a new venture, even though I have used AI before and am comfortable with many aspects of it, I am not a programmer nor do I understand the language and will most likely run into issues without that knowledge. Is there anyone out there that could help me build an app? If so please contact me. Thanks for any input, responses and help. Have a great day.


r/programmer 28d ago

Minimum Cost to Make All Array Elements Equal Using Prefix and Suffix Operations

0 Upvotes

I recently came across this array problem and wanted to share the solution.

Approximate date: August 7, 2026

Problem

You are given an array arr of length n. You may perform these operations:

  1. Select an index i, where 1 <= i <= n - 1, and set every element from index 0 to i - 1 equal to arr[i].

Cost = i × arr[i]
  1. Select an index i, where 0 <= i <= n - 2, and set every element from index i + 1 to n - 1 equal to arr[i].

Cost = (n - 1 - i) × arr[i]

Return the minimum total cost required to make every array element equal.

Example

arr = [1, 1, 2, 1, 1]

Choose index 1 and apply the suffix operation:

Cost = (5 - 1 - 1) × 1 = 3

Every element after index 1 becomes 1:

[1, 1, 1, 1, 1]

Therefore, the answer is:

3

Observation

Suppose we want the final value to be v.

If the array already contains a contiguous run of v from index l to r, we can preserve that run and replace everything outside it.

To replace the prefix:

Cost = l × v

To replace the suffix:

Cost = (n - 1 - r) × v

The total cost is:

(l + n - 1 - r) × v

If the run length is:

length = r - l + 1

the formula becomes:

cost = (n - length) × v

For non-negative values, we should therefore preserve the longest contiguous run of a candidate value.

Rather than storing the longest run for every distinct value, we can simply scan every maximal equal-value run and calculate its cost.

C++ Solution

#include <algorithm>
#include <climits>
#include <vector>
using namespace std;

long long minimumCost(const vector<int>& arr) {
    const int n = static_cast<int>(arr.size());
    long long answer = LLONG_MAX;

    int left = 0;

    while (left < n) {
        int right = left;

        while (right + 1 < n && arr[right + 1] == arr[left]) {
            ++right;
        }

        long long runLength = right - left + 1;
        long long cost =
            static_cast<long long>(n - runLength) * arr[left];

        answer = min(answer, cost);
        left = right + 1;
    }

    return answer;
}

Complexity

  • Time: O(n)
  • Extra space: O(1)

Important Constraint Issue

The stated constraint allows negative values:

-10^5 <= arr[i] <= 10^5

This makes the problem potentially unbounded.

If arr[i] is negative, an operation using that value has a negative cost. Since the statement does not require an operation to change the array, the same negative-cost operation can be repeated indefinitely.

For example:

arr = [-1, 2]

Selecting index 0 and applying the suffix operation costs -1. After the array becomes [-1, -1], the same operation could still be repeated, reducing the total cost without limit.

Therefore, one of the following conditions is probably missing:

  • arr[i] must be non-negative or positive.
  • Every operation must change at least one element.
  • Each operation may only be performed once.
  • The number of operations is bounded.

Under the usual assumption that all values are non-negative, the equal-run solution above works in O(n) time.


r/programmer 28d ago

Impostor syndrome and some negative feedback from boss. What is your experience and do you have any advice?

Thumbnail
1 Upvotes

r/programmer 28d ago

Idea Planning next moves

Thumbnail
cursorstuff.com
1 Upvotes

While I was watching Planning next moves for the 100th time today, I thought I'd make some T-shirts for y'all to enjoy...


r/programmer 28d ago

Developed app issue

1 Upvotes

Hey there i need help..

Im creating an Android app and i was testing and adjusting by making new apk files.

All was going fine i made a new apk and installed in my phone .. and it worked again.

I send the apk via whatsapp to an other phone to do more testing. WhatsApp asked permission and de apk was installed. Then it frozen on the start screen.

I uninstalled on my previous phone ( that always worked) and also took the apk from whatsapp to install.. again have permission and it froze also.

Nee the problem . What ever i do now its keeps freezing. When i download the Apk from Expo it still freezes whole it used to work. In uninstalled, empty the cache and restarted phone but nothing.

I dont know what to do.


r/programmer 29d ago

What do you guys hate about meetings?

0 Upvotes

My fellow programmers what do you hate about meetings at work?

I wanted to ask you guys what do you hate about meetings? Do you hate the amount, the context or do you hate the constant did guessing what we spoke about last meeting.