Interview practice plan
Lead Software Engineer (Java)
Mastercard · Pune
Practice content written by LYDJ for interview preparation. These are common questions for this kind of role, not this employer's actual interview questions.
What this role asks for
Skills we found in the job description. The plan below is built around them.
Sign in to see your gap areas first. We compare this role with the skills on your profile.
0 of 26 questions practised
Answer each one out loud, then tick it. Progress is saved in this browser only.
Java
This role asks for Java and Spring Boot. These Java questions cover the ground they share.
How does garbage collection work in the JVM, and how would you tune it for a low-latency service?
What good looks likeHide hint
Generational heap, G1 versus ZGC trade-offs, reading GC logs, and reducing allocation rate before reaching for JVM flags.
Explain the Java Memory Model. What do volatile and synchronized actually guarantee?
What good looks likeHide hint
Visibility versus atomicity, happens-before, and why a volatile counter++ is still not thread-safe (use atomics or locks).
When would you use CompletableFuture, a bounded ExecutorService, or virtual threads?
What good looks likeHide hint
Virtual threads for blocking I/O-heavy code, CompletableFuture for composing async steps, bounded pools for CPU-bound work, and the pinning caveats of virtual threads.
Agile
This role asks for Agile.
The team carries over stories every sprint. What do you do?
What good looks likeHide hint
Look at story size, work in progress, interruptions and dependencies, agree retro actions with owners, and track flow metrics such as cycle time.
How do you make retrospectives actually lead to change?
What good looks likeHide hint
Vary the format, focus on one or two actions with owners and dates, review last retro's actions first, and make it safe to speak honestly.
How do you coordinate several agile teams working on one product?
What good looks likeHide hint
A shared roadmap and dependency view, joint planning on a regular cadence, clear ownership boundaries, and lightweight rituals rather than heavy process.
TypeScript
This role asks for Angular. These TypeScript questions cover the ground it builds on.
What are discriminated unions, and how do they help with exhaustive checks?
What good looks likeHide hint
A shared literal field narrows the type in a switch; assigning the default case to never makes the compiler flag any unhandled variant.
When is using any or a type assertion acceptable, and how do you keep a large codebase strictly typed?
What good looks likeHide hint
Prefer unknown plus narrowing, enable strict mode, validate external data at the boundary, and tighten gradually with lint rules.
How would you keep frontend API types in sync with the backend?
What good looks likeHide hint
Generate types from an OpenAPI or GraphQL schema, share a contracts package, and validate responses at runtime where data crosses a trust boundary.
JavaScript
This role asks for JavaScript.
How would you find and fix a memory leak in a single-page app?
What good looks likeHide hint
Heap snapshots in browser DevTools, detached DOM nodes, listeners and intervals not cleaned up, and caches that grow with every navigation.
SQL
This role asks for SQL.
Find users who were active on at least three consecutive days.
What good looks likeHide hint
A gaps-and-islands pattern: subtract ROW_NUMBER() from the activity date, group by user and that difference, and count.
A query that used to take 2 seconds now takes 2 minutes. How do you debug it?
What good looks likeHide hint
Read the execution plan, check stale statistics, missing or unused indexes, data growth and skew, parameter-sensitive plans, and locking.
Explain transaction isolation levels and an anomaly each one prevents.
What good looks likeHide hint
Dirty reads, non-repeatable reads and phantoms across read committed, repeatable read and serializable, and how MVCC databases implement them.
Cybersecurity
This role asks for Cybersecurity.
Walk me through your response to a suspected compromised user account.
What good looks likeHide hint
Contain (revoke sessions and keys), scope using logs, eradicate, recover, communicate to the right people, and run a blameless review.
A scanner reports thousands of vulnerabilities. How do you prioritise them?
What good looks likeHide hint
Exploitability and exposure, asset criticality, known-exploited lists, compensating controls, and remediation SLAs by risk rather than raw severity.
How would you secure a cloud environment for a new product team?
What good looks likeHide hint
Identity first with least privilege, guardrail policies, central logging, encryption by default, network segmentation and secrets management.
System design
Lead / Manager engineering roles almost always include a design round. State requirements and rough numbers first, then walk through trade-offs.
Design a distributed cache. How do you handle node failures and hot keys?
What good looks likeHide hint
Consistent hashing, replication, eviction policy, protection against cache stampedes, and the consistency guarantees callers can actually live with.
Design a real-time chat system with one-to-one and group messages.
What good looks likeHide hint
Connection handling (WebSockets), ordering and delivery receipts, offline storage and sync, fan-out for groups, and presence.
Your service's p99 latency doubled after a release. Walk me through how you investigate.
What good looks likeHide hint
Check what changed, compare dashboards and traces, isolate by endpoint and dependency, roll back first if users are hurting, then find the root cause with profiling.
Behavioural
Every interview loop has a behavioural round. For lead and manager roles, the focus is on people decisions, prioritisation and leading through change. Use the STAR structure.
Give an example of when you went beyond your role to fix a problem for your team or a customer.
What good looks likeHide hint
Pick something with real impact, explain why it mattered, and how you involved the owner rather than quietly working around them.
Tell me about a time you influenced an important decision without having formal authority.
What good looks likeHide hint
Cover how you built the case (data, prototypes, allies), handled objections and what changed. Strong answers show patience and shared credit.
Why do you want this role, and why now?
What good looks likeHide hint
Connect two or three specific requirements of the role to your experience and to a direction you are deliberately moving in. Generic praise of the company scores poorly.
Describe a time you had to deliver bad news to a stakeholder.
What good looks likeHide hint
Show that you told them early, came with options and a recommendation rather than just the problem, and kept their trust.
Leadership
The title marks this as a lead or manager role. Expect questions on hiring, developing people and setting priorities.
How do you handle a team member who is consistently underperforming?
What good looks likeHide hint
Diagnose first (skills, motivation or context), set clear written expectations, support with a time-boxed plan, and be ready to make a fair hard call.
Tell me about a time you resolved a conflict between two people on your team.
What good looks likeHide hint
Show you addressed it early and privately, focused on behaviours and shared goals rather than personalities, and followed up afterwards.
How do you keep a hybrid or distributed team aligned and engaged?
What good looks likeHide hint
Name concrete rituals (written plans, demos, regular 1:1s), how you spot disengagement early, and one thing you changed based on team feedback.
Company research brief: Mastercard
From the roles we track on LYDJ, refreshed daily from the official careers page.
126
open roles
24
added in 30 days
66
in Engineering
Hiring most for
- Engineering66
- Data & AI17
- Other17
- Finance & Legal9
Read before the interview
Questions to ask them
- ›There are several open Engineering roles at Mastercard right now. How is the team growing, and where does this role fit?
- ›The company hires in Pune, Gurugram, Mumbai. How do teams across locations work together day to day?
- ›How does the team use Java and Agile today, and what would you like to change?
- ›What does success look like in this role after six months?
- ›What is the biggest challenge the team is facing this year?
Preparation checklist
0/8 doneSaved in this browser only.