Google Software Developer Interview Questions & Answers
Behavioral
1. What are some of the testing and debugging processes you use in your software development?
How to Answer
This is either a standalone question or a follow-up to a previous question. If you previously told the interviewer about the QA processes you use, you should now discuss your testing and debugging processes. During a Google interview, you should always anticipate follow-up questions whenever you answer an interviewer's question. This is why you keep your answers short and direct. It creates an opportunity for the interviewer to dive deeper into the topic if they have a specific interest in it or move on to a new line of questioning.
1st Answer Example
"I typically use unit testing tools to identify errors in my code when I develop software. I follow this with a debugging process and additional testing of the bug fixes. This is known as White Box Testing. The debugging tools I use most often are GDB and DBX, which are both public domain products. I prefer these because they provide command-line interfaces. I used command-line when in school, and it has always been easier for me to work with than a GUI. Some other tools I use are code-based tracers, profilers, and interpreters."
Behavioral
2. What are some of the software design patterns that you use, and in what situations do you use them?
How to Answer
Interviewers ask you operational questions during an interview for a software developer's position with Google to determine how you complete the tasks required by this role. They also want to learn that your techniques are similar to those of the Google development team. Operational questions are best responded to succinctly and directly. You should always expect follow-up questions when a Google interviewer is asking about a specific task. This indicates that they have a special interest in the topic they are questioning you about.
1st Answer Example
"Throughout my career, I've tried several different software design patterns. Some of these were Singleton, MVC, and Iterator. However, the one I use the most is Template. This design pattern helps me code straightforwardly and accelerates the software development cycle. It also results in fewer errors and less debugging."
Behavioral
3. How do you approach implementing an LRU Cache in your favorite programming language?
How to Answer
Having a favorite programming language tells a lot about the experience and expertise level of a software developer. There are numerous languages to pick from, and depending on what applications you are working on and what you intend to achieve, some might work better than others. The Google hiring manager might start with a question about your favorite language and then move to your approach and possibly your methodology or reasoning for favoring that language. Let me give an example of how this question might be answered. If we intend to use Java for this example, we would look at the LRU cache and recently used entries, then remove the element from the bottom and add an element to the start of a LinkedList. Wherever any entry is accessed, it is moved to the top so that recently used entries will reside at the top, and the least used entries will reside on the bottom.
1st Answer Example
"The way I approach implementing an LRU Cache is based on what programming language is used in the development environment. Yes, I do have a preference, but I consider it a tool in a toolbox; I use whatever is available to me to easily adapt my process to the ones used here at Google. Java seems to be a tool of choice in most development environments, and for me as well. Say, for example, we are given total possible page numbers that can be referred. We are also given cache (or memory) size (number of page frames that the cache can hold at a given time). The LRU caching scheme is intended to remove the least recently used frame when the cache is full, and thus a new page is referenced which was not in the cache before. Examples of this approach and method are referenced in the Galvin book."
Behavioral
4. What software development process do you prefer to use?
How to Answer
This is an opening or general question a Google interviewer will ask to begin a conversation, get you talking, find out a little more about you, and collect information they can use for subsequent questions. They are also interested in learning whether the processes you use align with those of Google. The best way to prepare for this type of question is to research the organization, its software development processes, and the tools it uses. You can learn this from the Google website, the job description, or by speaking with former and current Google software development team members.
1st Answer Example
"The software development process I use the most is the same one I learned early in my career. It begins with a rediscovery process and requirement analysis, which leads to the specifications and software architecture. I then move on to development, testing, implementation, and documentation. After this is done and the software is fully developed, my attention turns to training the Google users, assisting the support team to be prepared to respond to issues, and providing ongoing maintenance, bug fixes, and upgrades."
Behavioral
5. Describe how do you implement an insertion sort algorithm, and what's the easiest way to do it?
How to Answer
If the Google interviewer asks ten software developers to describe how to implement a sort algorithm, they will probably get 10 slightly different but related answers. Every software developer has a method and a work style of their own that works for them and makes them efficient at their job. An interviewer in this case wants to hear about the method you use and if you take any shortcuts to arrive at the final product. They want to know if you take shortcuts that could compromise the quality of work you are doing. They would like to hear about your development methodology and how you implement an insertion sort algorithm while doing your due diligence and quality checks along the way. In simple terms, the way an insertion sort works is it starts from the index 1 (not 0), and each index starting from index 1 is like a new card that you have to place at the right position in a sorted sub-array on the left side.
1st Answer Example
"I can give several examples of Insertion Sorts, but I think to give you a better explanation, it would make more sense to list in detail the characteristics of an Insertion Sort. Let's start with the first one.
1. There are two types...Selection Sort and Bubble Sort algorithms.
2. They are efficient for smaller data sets but very inefficient for larger data lists.
3. The stable sorting technique does not change the relative order of elements that are equal.
4. It doesn't take up much space. Unlike bubble sort, an insertion sort also requires additional memory space.
5. An Insertion Sort is adaptive, which means it reduces the total number of steps required for a partially sorted array to provide input."
Behavioral
6. How would you define software configuration management?
How to Answer
In simple terms, software configuration management is the process of systematically managing, tracking, and controlling changes that happen in the software development lifecycle. This includes changes in the code, documentation, and process. Change control, however unpopular, is a function that ensures all changes made to the software system are consistent with Google development practices and internal methodologies. The ultimate goal is to see productivity improvement with a minimal amount of mistakes throughout the development lifecycle. Here, the interviewer is looking for how you prioritize configuration management duties and responsibilities, and your experience with controlling something even if you don't know what it is. This can be tricky, so let me explain. Configuration management is used if there are multiple team members working on a software or revision which is running on multiple machines or needs constant updating. Another reason is if a company has multiple locations or divisions that need to distribute work concurrently.
1st Answer Example
"My definition of software configuration management is a set of activities that identify a number of items including source code modules, test cases, requirements specification documents, tools used, objects, files, and CSCI in SCM repositories, just to name a few. There are also other important activities that I coincide with these actions as well. The first thing I look at is a baseline, which lets me know the accepted version of a software configuration item. The second is change control, which is a method that ensures quality and consistency when changes are made. Third on this list is configuration audits, which verify that the software meets the minimum baseline needs, and the deliverable is being met."
Competency
7. How much do you know about object-oriented programming?
How to Answer
There are two different types of programming. These include Object-Oriented Programming and Functional Programming. Knowing the differences between these two approaches and their benefits is critical for an experienced software developer. Interview questions are meant to probe your knowledge, experience, and qualifications for this position. Google interviewers use a wide range of technical questions to help them accomplish this. This is an example of this. Technical questions are easily answered by defining the term you are asked about and then discussing its features and benefits. You can also provide an example of how it is used to illustrate your answer.
1st Answer Example
"I am very familiar with Object-Oriented Programming, also known as OOP, and use it a lot. This type of programming defines the data structure and the types of operations applied to the data. I like this approach because it helps me organize my code logically around a specific parameter. It also makes it easier to maintain and document the code. Finally, objects can be inherited and extended, which accelerates and shortens the software development life cycle."
Competency
8. What method do you use to find the missing number in an integer array of 1 to 100?
How to Answer
When it comes to interview questions about finding missing numbers in an integer, that tells me that the interviewer at Google has a specific type of role in mind for a candidate. More than likely, they are looking for an analytical thinker who can solve problems relatively easily. Let me demonstrate. Let's say I have an array number from 1 to 100. These are just random numbers for now. In a sorted array, you can compare whether a number is equal to the expected next number or not. Alternatively, you can also use the BitSet method in Java to solve this problem as well. A BitSet solution is more general, as you can use it to find more than one missing value on an integer array. Take your time to think about how you will respond to these questions because the interviewer is testing your ability to process and come up with an answer.
1st Answer Example
"Having many tools at my disposal, I find that a Java solution is the best way to solve this problem. I would typically write a program to find the missing number in an array in Java, C#, or another language. I use the method to find missing elements in an area of 100 integers, which contains numbers between 1 and 100. Looking at this problem from a high level, this can easily be solved by calculating the sum of the series using n(n+1)/2 to solve this problem. It's a quick and efficient way to do it, but keep in mind that it cannot be used if the array contains more than one number or if the array contains duplicates. To arrive at the correct answer, these solutions might require you to calculate the sum of numbers and then subtract that from the actual sum. Is this similar to the methodology used here at Google?"
Competency
9. I've heard applications referred to as both software and programs. Which terminology do you use, and how do these differ?
How to Answer
During a software developer interview with Google, you will be asked to discuss terms, processes, and other aspects of your job. A Google interviewer will ask these questions to explore your knowledge, skills, experience, and qualifications for this job. When presented with two similar but different terms, you should be prepared to compare and contrast them. Start by defining each term and then discussing their differences.
1st Answer Example
"It is common for people to confuse these terms. While they are similar, there are subtle differences between them. My definition of these terms is that a computer program is a set of code that executes specific tasks. This typically takes the form of an application. Computer software is any code that performs a function on a computing device. These can include the operating system, drivers, system software, APIs, applications, and other code. Computer software includes computer programs, but computer programs don't always include all the software. Computer Software is more machine-centric, while computer programs are more user-centric. I'm curious, does Google similarly define these terms?"
Competency
10. Making a comparison, how would you differentiate between Quality Assurance and Quality Control, as you believe it is implemented here at Google?
How to Answer
Anyone in the quality field, be it Software (IT), Engineering, Production, etc., should be able to differentiate between the two. Depending on what specific role you have with a quality task, it will be wide-ranging. To help you understand the difference between the two, let me give you a better idea of what they are and do. In short, Quality Assurance checks if proper processes are being followed, while Quality Control deals with maintaining the quality of a software product. If the Google hiring manager you are meeting with has any responsibility for QA or QC in their department, they will likely ask you to differentiate the two. Things that they might want to hear are things like the following:
Quality Assurance - Assures that the approach and/or method used to produce a part are designed and implemented correctly.
Quality Control - A process used to test, verify, and identify a defect. It also ensures that the approaches, techniques, and methods are designed and followed correctly.
1st Answer Example
"Based on my research, I believe that here at Google, quality control and quality assurance work hand in hand in a software development environment. Every software development project that I have worked on required a detailed specification document that includes QA and QC as part of the (SDLC) Software Development Life Cycle.
With Quality Assurance, I always perform the following: Prevent defects in development coding, apply statistical process controls, and define standards that need to be followed. As for Quality Control, I also always perform these tasks: Aim to identify and improve the quality of programming code, perform validation early in the development process, and follow pre-defined processes, policies, and standards."
Competency
11. Talk about the differences between structured English and Pseudo Code.
How to Answer
Let's begin with what structured English and Pseudo Code are. Structured English is the native English language. Its primary purpose is to write the structure of a program module. It uses programming language keywords to achieve this. On the other hand, Pseudo Code is like a programming language without the syntax of any specific language. This question can come in different forms, and each Google hiring manager will ask it differently, but essentially they are asking the same question. Pseudocode is a kind of structured English used for describing algorithms. It describes the entire logic of an algorithm so that when implementation happens, it is translated line by line into source code. This is an algorithm question that the Google hiring manager asks to see if you're old school and if you've written code in Lisp, FORTRAN, or C programming language. This tells the manager how you approach a project, whether it's task structured or methodology driven. Either is not a wrong answer, but you want to ask the interviewer what type of development organization they run early in the interview so you can answer accordingly.
1st Answer Example
"My approach is simple: I take an organized approach to how I write code, and the way I differentiate structured English and Pseudo Code. First, I make a list of the main tasks that need to be accomplished. Then, I break them down into small manageable tasks that can be explained with a short phrase. It's been my experience that the further I dig into the correlation between pseudo code and real code, I find that pseudo code helps me plan the structure but doesn't help me resolve the real-world programming. In my opinion, that's the bottom line difference in simple terms between the two. Since either is actual programming languages, they act as structured algorithms that can be used in a programming language."
Competency
12. Explain how duplicates are removed from an array without using a library.
How to Answer
If we look at the core of this question, it has to do with an array not finding duplicates. The goal here is to be able to remove duplicates from an integer array without using any collection API class libraries. Several levels of interview questions will come up to test your knowledge of basic to complex problem-solving solutions. This one sits somewhere in the middle of the pack. When an interviewer asks whether or not you need a loop or recursion (depending on your skill level), she/he is asking the order in which elements are inserted in a Set. Answering with something like 'An array is a static fixed-length structure that cannot change its length' is probably something that will tell the interviewer that you have a solid understanding of how deleting an array works.
1st Answer Example
"Having worked at many levels using arrays and class libraries, this is a pretty straightforward answer. If your input array contains multiple duplicates, this may result in many temporary arrays, some of which may not be needed. With this restriction in mind, I typically figure out how to minimize both memory and hardware requirements. In cases where I need to delete an array using a more defined descriptive logic, the approach I take here is to find duplicate elements in a given array, then run an outer loop to 0 to size. As a next step in the process, I run another inner loop to find the first duplicate using another nested loop. To take it further, inside the inner loop, I also check for duplicate elements. If I find one, then I delete the array element."
Competency
13. Prior to starting any software development project here at Google, we perform a feasibility study. What is your opinion on a feasibility study, and when should it be done?
How to Answer
As a prospective Google Software Developer, you need to look at things from a broader perspective to gain a bigger picture of what your internal customer (department) or external customer (client) wants. In the early stages of the software development cycle, you may find that a feasibility study might be required. There are two important factors to consider before determining whether or not a feasibility study is required. A feasibility study is broken down into two essential categories. The first is Technical in nature, and the second is an Operational view. The Google interviewer wants to know if you follow protocol by offering a feasibility study to the client or go through the motions of your job. It's important to mention this in your interview because it helps crystallize in the interviewer's mind that you go above and beyond the norm to get the job done right. Again, the interviewer is asking for your opinion, so it's important to express your opinion to explain why you think it should or shouldn't be performed.
1st Answer Example
"In my current role, I was asked by senior management whether or not a feasibility study would provide insight into potential productivity improvements and cost-saving measures within the organization. I took on the task of planning and executing a feasibility study to determine what type of outcome we could expect. I gathered a team, formed a committee, and assigned each team member a task, goal, and phased timeline to report their findings. After the feasibility study was completed, we analyzed the data and found that there was just cause to perform a full-scale feasibility study. The results provided insightful information about what areas of the company needed further analysis and other areas that started seeing improvements. We selected the technology, production, operations, and accounting for this study. After all the data was analyzed, I provided a draft of our findings to management for review for accuracy, relevance, and completeness. I was praised for this project since it did help the selected departments in every aspect of the operation."
Competency
14. What is software scope, and what does the process involve?
How to Answer
Software scope is a set of activities and actions to be performed as part of the delivery of a software product. Software scope should be well defined with phase-by-phase milestones, functionalities, and deliverable components. A question like this will be asked during an interview with Google regardless of your experience level in software development. This is a fundamental question that all software developers should know and know well. Let me give you some clarifying pointers that you can use for a better explanation and response. Software scope identifies a few different but essential elements including what the product will do, what is outside the scope of the project (what is not to be done), what the timeline is for completion of the project, who is documenting the list of deliverables, goals, tasks, and what the estimated cost of the project will be. One more part should be covered because it comes up more times than not in a Google interview. Project Scope creep. This is when the project experiences changes or uncontrolled growth during the project because the project was not well defined, documented, or controlled early in the project specification phase.
1st Answer Example
"Software scope, for me, is relatively easy because at my current company, I'm involved at every stage of the documentation and project delivery process. It is my responsibility to identify all aspects of project scope including, but not limited to, what the end product will do, what the expected timeline will be, who needs to approve deliverables at every phase, what the goals and tasks will be for assigned team members, how the features will work and their characteristics, and what the estimated cost will be for the final product. As part of my due diligence, I always draft a Project scope document that includes items that are not part of the scope of work. This helps eliminate any confusion or miscommunication with the Google client."
Competency
15. If hired by Google, one of your tasks will be to debug your and other developer's code. As a software developer, explain the meaning of debugging and why it's used?
How to Answer
In the software debugging world, the process starts as soon as code is written and continues in successive stages of the development process and is then combined with other units of programming to form a software product. Debugging is a multistep process that involves identifying a problem, isolating the source of the problem, and then correcting the problem. Please remember this since the Google technical manager who knows development and debugging well will quiz you on multiple facets of this area. It's essential to note that hiring managers will want to find out how good the quality of your code is. The reason is they will know how much time you will be spending on the debugging process. If you maintain a high-quality code level, you'll be doing less debugging; if your code is average or not great, you'll be spending a lot more time debugging, which managers might see as a weakness. Please be aware of this.
1st Answer Example
"In short, debugging is an important part of determining why an operating system, application, or program is behaving abnormally. When I do debug, there are many things that I take into account during this process. For larger lines of code, I conduct unit testing and pair programming, which helps me identify bugs at an earlier stage. I also use the stand-alone debugger tool to identify bugs further. I've always been conscious of my work and only want to produce top-quality work. To further understand where bugs may reside, I also look at the module to see if the problem avails itself. If not, I set up a 'breakpoint' and run a program to see it run its course. After performing debugging and testing, I do come across errors that I address and correct immediately. Some examples are...Syntax errors, Runtime errors, Logic errors, Semantic errors, etc. Does this mirror the process you use here at Google?"
Competency
16. What are verification and validation, and why are they important?
How to Answer
Verification and validation are crucial in the software development process. If you can't verify or validate a set of activities to ensure that the software is not implemented correctly, hasn't been built to specification, or is functioning properly, you will surely have problems with your production environment. Google interviewers know how important this is and will ask questions about it to ensure that you practice doing your due diligence to ensure the highest quality software development. When questions come up about verification and validation, it might score you an extra point in the interview if you give the Google interviewer a history of how V&V was formed. It is an application of Six Sigma and its principles. It was used to design products in the manufacturing and support process areas. It's important to remember, if asked, that there are two critical aspects of software quality management. Verification answers the question of whether the software is being developed correctly, and validation provides the answer to whether the right software is being produced.
1st Answer Example
"In my opinion, verification and validation are at the heart of every development project. I take this step very seriously, and it shows in my work. This, of course, includes all the steps and procedures of validation. Prospective validation is important because it is done to ensure the product is functioning properly. Retrospective validation is done against the written specifications and verifies actual data. Periodic validation is used to repair, relocate, or dismiss data that serves no purpose. Partial validation is mostly used for research but can come in handy for pilot studies. Cross-validation is suitable for estimating the performance of statistical models. Concurrent validation is usually carried out during regular maintenance or service routines in the post-development process."
Competency
17. Describe at a high level what the software development life cycle process is.
How to Answer
SDLC, or Software Development Life Cycle, is a software development process that produces software in the most efficient way possible. SDLC includes a detailed plan for how a software application can be developed, altered, maintained, or even replaced. SDLC involves several distinct stages, which include planning, design, building, testing, and deployment. Depending on what level of hiring manager you are interviewing with, you'll need to answer questions related to the SDLC life cycle. If the manager is hands-on, has a history of writing code, and knows the SDLC, you might want to mention what types of methodologies you have used. Some of the most popular ones are Waterfall, Agile, and Spiral Model. If you're interviewing with a senior-level manager that hasn't done much coding but understands the SDLC, then your answer might be a higher level (strategic response). Either way, it's good to have a solid foundation of how SDLC works. The whole purpose of creating the SDLC foundational architecture is to lower the cost of software development while improving quality and shortening production time.
1st Answer Example
"I have sound knowledge of the entire SDLC process, and have used it as the foundation of my development in my career. During my development career, I have used a few different SDLC methodologies that I am very comfortable with. They are Waterfall, Agile, V-Model, Iterative, and Spiral Model. I fully understand SDLC, but also the critical stages that are required for quality software development and execution. It starts with the following stages:
Requirement analysis
Technical and business specifications
Software architecture and infrastructure
Implementation/Integration
Testing
Documentation
Training and support
Maintenance"
Competency
18. Can you list for me the important categories of software development?
How to Answer
Believe it or not, the world of software development is an important part of our daily lives. Without it, we wouldn't have all the wonderful Google apps and mobile technologies that we use daily. Not only is software development important in our lives, but it is a highly sought-after skill for companies that can't find enough of this type of talent. Speaking of in-demand occupations, the Bureau of Labor Statistics projected a 30% employment growth in the software development field by 2026. Let's talk about some questions that may come in the course of an interview. Many Google hiring managers test software developers by asking what type or category of software development they have worked on. Software developers will tend to work in special development areas where they have a comfort level. Most software developers should know the nine basic types of software development even if they haven't worked directly in that category. For reference purposes and preparation, here are nine different kinds of software development:
1. Mobile Development
2. Web Development
3. Back-End Development
4. Application Development
5. Data Science Development (Data Analytics)
6. API Development
7. Security Software Development
8. Embedded Systems Development
9. Cloud Computing Development
1st Answer Example
"I'm quite familiar with all the categories of software development, especially those used here at Google, and I have coded in most of them with a high level of confidence. I have worked on Web Development - building front-end web pages in Java, WordPress, HTML, PHP, and ASP. NET. Mobile Development - building web apps on HTML5, Java, C# and Objective C. Application Development - typical app dev with tools like VB.NET, Python, C++, C#, and Java. Data Science Development (Data Analytics) - This is a fun one for me. I've been building intelligent data warehouses and data sets for scientific applications using tools like MATLAB, Python, and C++. Back-end Development - this type of work is mostly server-side database-driven development which requires different programming languages and architecture. Some of the development tools I have used here are dBase, Oracle, SQL Server, Java, Python, and C++."
Competency
19. Google software developers use a variety of different sorting algorithms. Tell me the difference between a Comparison and Non-Comparison Sorting Algorithm?
How to Answer
This is a common Google interview question asked of software developers. This question, believe it or not, doesn't have an easy or unambiguous answer. On the one hand, the speed of sorting can depend on the environment in which the sorting is done, and on the other hand, it can depend on the type of items that are sorted and the distribution of these particular items. For example, if you are sorting an extensive database that cannot fit into memory all at once, this would be quite different from sorting an array of 100 integers. Adding to that, not only will the implementation of an algorithm be quite different, but it may even be that of the same algorithm. It might also help to know the five Sorts that will likely be brought up in an interview. They are: Quick Sort, Insertion Sort, Shell Sort, Heap Sort, and Merge Sort. Study them and research examples of how they are used and the differences between them. I will give examples that you can use here as well.
1st Answer Example
"One of the first things I do before making any comparison is to use a test environment to test the speed of the different sorting algorithms (Comparison and Non-Comparison) in this case. I test each algorithm several times for randomly generated arrays to gather the most accurate data before proceeding to the next step in the process. The next step is to look for random numbers between 0 and 10 times the array size to create array content. I may or may not do a high-repetition test with numbers between 0 and 1/100 times in the same context. After I do this, the results may come back as completely random, sorted, or reversed. I would also run some test-cases to determine the number of repetitions from low to high for each value if the array repeats."
Competency
20. Can you walk me through the meaning behind a Depth First Search Algorithm for a binary tree?
How to Answer
When looking at a question of this magnitude, there are several different factors to consider. You will want to get clarification from the Google interviewer on whether they want to hear the meaning for tree structure data, time complexity, extra space, or a node stack. Let's examine what some of these mean and how they might come up in the course of an interview. Time Complexity - has four transversals O(n) as they visit every node exactly once. Extra space - requires O(w) Level Order Transversal where w is the maximum width of a Binary Tree which stores nodes of different levels.
1st Answer Example
"I'm familiar with the meaning of this question. There are a couple of ways to answer it, so I will give you both examples. The two most common methods of searching a graph or a tree related to a depth-first search are depth-first search and breadth-first search, for starters. Depending on the application you are using and the result you want to achieve, this should be determined by the type of data in your tree or graph data structure. For a Breath First Search, I start at the root node. I then search all their children nodes moving from left to right, then I repeat the process at the level below the root node. I typically repeat this on each level until I reach the end of the tree or node. As a general practice, I use a queue as an intermediary step as a way of keeping track of what nodes I need to search."
Competency
21. How do you find the starting node of a cycle if a link contains a cycle?
How to Answer
Let's say for argument's sake that two cyclists (no pun intended) are pointed at the beginning of the starting line with their cycles. For clarification purposes, the two cyclists are the pointers. In this example, if we move cyclist one step at a time and the second cyclist two steps at a time, they would eventually meet at a single point. An interviewer wants to know whether you can explain how you arrive at an answer and the reasoning behind your findings. This is important because when you explain if a link contains a cycle, you need to back that up with a verbal or written (whiteboard) example. A common response might be the mention of, let's say, that a meeting point is 'P' steps away from the beginning of the cycle, and the 'cyclists' meet when cyclist one has taken a '7' total steps toward the point.
1st Answer Example
"The way I find a starting node of a cycle is to measure the length of 'R' and how far the distance is away from the cycle. That's a simple explanation. A more complex explanation I can illustrate is when cyclist 1 travels double the speed of cyclist 2, they both arrive at the same meeting point when time is constant. Since there are several examples I can give to make my point, I would like to share one more. The next pointer of each node that is traversed is made to point to this temporary node. This way, we are using the next pointer of a node as a flag to indicate whether the node has been traversed or not. If I come across a node that points to null, then the loop doesn't exist. If I find that the code runs in O(n) time complexity and uses constant memory space, then that tells me that this needs to be researched further."
Competency
22. Here at Google, our developers work with Java quite a bit. Tell me how you find duplicate numbers in an array in Java containing multiple duplicates?
How to Answer
You will find that Java is used with many applications, on many different platforms, and a multitude of languages as well. If you're in software development and haven't learned to program in Java, I suggest you learn it as soon as possible. It is becoming a core technology for web development and development in general. It has many capabilities that other programming tools don't have, and that's why it's been a favorite for many developers and companies such as Google. Everyone in IT has their own way of approaching a complex problem and finding a solution. In this case, we're talking about finding duplicate numbers in an array in Java. Luckily, Java is a go-to for most developers trying to solve this problem. An interviewer might phrase this question differently, but this is the easiest to understand. When you hear the words Sorted or Binary search, they are looking for you to explain what inner and outer loops mean or parsing items inside an array. Be prepared for those questions as well.
1st Answer Example
"Problem-solving has always been a strength of mine. I take them on intending to find a solution to a problem in the shortest time possible. I was working on a Java development project that required using Binary Search and Sorting. I started by adding a duplicate list of elements inserted back into an array. I also used two pointers to solve this, one to compare an element and its closest neighbor to maintain a distinct element. Another method that I tried was by parsing all the items inside of an array containing 'n' to give me O(n). This way, we get an array of the n+1 element with integers between 1 and 4, which means there will be at least one duplicate as a result."
Experience
23. As part of software development, were you involved with working on functional and non-functional requirements?
How to Answer
In short, functional requirements are functional features that users expect from a proposed software product. Non-functional requirements, on the other hand, are more related to security, performance, and the look and feel of the user interface, a.k.a. (UI). For a project to be successful, it is critically essential that both the customer and the Google project delivery teams have a clear definition and agreement on what the project scope and detailed requirements are going to be.
There are three types of requirements: conscious, unconscious, and unidentified or TBD requirements.
When the Google hiring manager asks this question, they want to know if part of your job requires gathering and analyzing functional or non-functional requirements. For functional requirements gathering, they will want to hear how the system behaves under certain conditions within its environment, how it responds to inputs, and what outputs it generates. As far as non-functional requirements, they will want to also hear things like constraints on the system, quality attributes, security, performance, and availability.
1st Answer Example
"Yes, I work with cross-functional teams within our organization on functional and non-functional requirements. I take a unique approach to address these types of requirements. It's a step-by-step method, really. There are three requirement types that I use. Conscious, unconscious, and unknown requirements. Consciousness is when stakeholders have a high-level awareness of the basic requirements. Unconscious is what stakeholders would like to see but didn't translate the message enough to see the desired result. This stakeholder assumes that the work they envisioned will be delivered, which in most cases falls short of their expectation. Unknown is the type that has yet to be imagined or realized. Stakeholders typically don't give input into this type because they assume it is not achievable or cannot be delivered as expected."
Experience
24. What is your experience with implementing a Binary Search Algorithm without recursion?
How to Answer
This is the type of question an interviewer will ask if he starts to doubt your ability to perform certain duties revolving around algorithm-based development. Since software development, at some level, relies on algorithms and data structures, this will be an important question that you must understand and answer properly. If we look at how the binary search structure is broken down, it contains a binary search or half-interval search, which is a divide and conquer algorithm that seeks a position of an item in a sorted array. When a hiring manager asks about comparing inputs and output to the middle element of an array, they are asking if a search returns the position of an element. It's important to know and understand this concept. Another question that may be asked is whether or not an input is less than or greater than an element. If you have a sound understanding of these concepts, ask the interviewer what level of detail they would like to answer their question. Some interviewers only want to hear a high-level answer, and others want a detailed explanation.
1st Answer Example
"I have extensive experience and hands-on knowledge implementing binary search algorithms with and without recursion. For this answer, I will talk about BSA without recursion. Binary search algorithms typically halve the number of items checked for each successive iteration, thus locating the given item in logarithmic time. Furthermore, a Binary Search Implementation in a Java algorithm is implemented recursively respectively. Also, I would like to share an interesting fact that binary search algorithm implementation is mostly done without recursion. It is also known as iterative binary search."
Experience
25. What are some of the types of development projects you have worked on in your past positions?
How to Answer
Organizations like Google prefer to hire candidates who have direct experience with the type of work they do. An interviewer will ask this question to determine if you've recently done the type of work they want to hire you for. During an interview with Google, all your answers should address the needs of the employer. It would be best to discover these during your pre-interview research about Google, its products, and practices. You can find the information you need in the job posting and on Google's website.
1st Answer Example
"In my last two roles, I was focused on improving applications which manage transactions and interact with relational database systems. My role in the application development was developing all the code to control data queries, lookups, and indexing of the data. I worked with other programmers to design the interface, manage the backend database, and develop other application features. The companies I worked for were focused on e-commerce, conducting sales and other transactions via their websites."
Experience
26. Based on your experience, what's the best way to find a node that begins with two single link lists?
How to Answer
You will find that Google interviewers like to ask candidates about the various methods they use to find nodes and link lists. Don't be surprised if this question comes up a couple of times in an interview but is asked differently. To get a broader understanding of linked lists, here's an overview: A linked list is easiest explained as a linear data structure with the collection of multiple nodes, where each element stores its data and a pointer to the location of the next element. The last link is essentially a linked list that points to null, which indicates it's at the end of a chain. An element, on the other hand, in a linked list is called a node. The first of the nodes is called the head, and the last of the nodes is called the tail. An interviewer will likely dig into questions about linear data structure and which nodes contain a value and pointer.
1st Answer Example
"The best example I can give is to list the most important properties of a class Linked List. This highlights how they are used and why they are used.
A Linked List maintains an insertion order of the elements.
Implements Queue and Deque interfaces. These can also be used as a Queue, Deque, or Stack.
A Linked List can contain all the elements, including but not limited to duplicates and null.
A Java Linked List Class library is not synchronized, which means in a multi-threaded environment, it must be synchronized concurrently for external modifications to the linked list.
A Linked List Class doesn't implement a Random Access interface so that elements can be accessed in sequential order.
I can use a List Iterator to iterate elements of the list
I can use a collections synchronized List (new Linked List) to get a synchronized linked list."
Experience
27. Can you describe a challenging software development project you recently completed and the results?
How to Answer
Ideally, you have encountered some of the same challenges that Google has during your software developer experience. The interviewer hopes to confirm this. It demonstrates that you will address the challenges and problems they encounter and help them resolve them quickly. Google hires people to either fill a vacant role or expand their team. In either case, they expect the candidate to bring a fresh perspective to the organization and skills, experience, and knowledge they currently don't have on their team. Your answer to this and all the questions they ask should affirm this.
1st Answer Example
"The most challenging software project I've worked on recently involved an application to allow the company's personnel to self-manage their HR benefits. The challenge was that end-users had to have secure access to their information without the HR staff intervening. This required me to implement several security features, including user authentication, password protection, and the ability for users to access the company's database behind its firewall via VPNs. Recognizing that I did not have recent experience in these technologies, I refreshed my skills by taking a short online course and collaborated with some of the other developers on our team on the project. Together we developed the software on schedule and under budget. I learned to recognize my shortcomings and bring in additional resources when needed."
Experience
28. What are some of the QA processes you are familiar with and have worked with in the past?
How to Answer
While a software developer may not be directly involved with the testing and quality assurance of the code they develop, who should be familiar with the processes. This will help them code for the requirements of Google. The interviewer uses this operational question to determine the type of quality control systems you have worked with and confirm that your processes are similar to the ones Google uses. Even if your experience isn't an exact match to theirs, you should be able to describe how you would quickly transition to Google's processes.
1st Answer Example
"Because I develop software using the Agile framework, the quality control processes I encounter the most are the ones used within this framework. I have worked with Waterfall, Just In Time, and SQA as well. I feel comfortable transitioning between QA processes, and I am confident I can easily adapt to the ones that the Google team is using."
Personal
29. Do you have a preferred language that you like to write programming algorithms?
How to Answer
No matter what level of expertise, every developer has their views and opinions when it comes to programming language choices. It's much like a toolbox; you use them based on the specific need to solve a problem or fix something. One of the reasons an interviewer will ask this question is to see what range of tools you have used and which you prefer using. It always helps to start by stating that you have used several languages and have a high confidence level with all of them, but if you had to pick, give them a range and narrow them to one of your favorites. Don't be surprised if an interviewer asks why you like that language and what benefit it gives you. If the interview is going well, it wouldn't be a bad idea to talk about some of the strengths and weaknesses of a few that you have used.
As a reference, the top languages likely be Python, Java, JavaScript, C, C#, Ruby, PHP, Swift, and SQL.
1st Answer Example
"Every software developer has a preferred language, and I'm no different. There are a few that I like, and I would put them on my preferred list. Let me start by giving you a few that I have found very useful in various environments. Perl is probably is among the top for me for several reasons. Compared to Python, it is about three times as fast when reading PASTA files, and it only needs half the storage space to store sequences in memory. Java is another one of my preferred favorites, again for many reasons; not only is it good for programming algorithms but it can be used across multiple platforms, including web applications. Lastly, in this group, I need to include C# because it requires less memory for holding strings and less time to read these types of files than most other languages."
Personal
30. Are you familiar with Agile and Waterfall? Which of these software development methodologies do you prefer?
How to Answer
A Google interviewer will ask this question to determine if you are a good fit for their organization. There are a lot of different methodologies software developers can choose from. Regardless of which one you prefer, you'll need to adapt to the software development methodology used by the organization with whom you are interviewing. You can learn about the methodology Google's software development team uses should through your pre-interview research. The method you state a preference for should align with the one the company currently uses.
1st Answer Example
"The software development methodology I use the most and prefer is Agile. The reason I like this iterative framework is due to daily stand-ups. These provide the team with the opportunity to discuss its development goals and any issues that they've encountered. I prefer to use the Agile methodology because it identifies errors and enables them to be corrected at each stage of the process. The result of this is better quality software and a reduced need for debugging toward the end of the project."