r/CS_Questions • • Aug 22 '20

Cloud data engineer at goolge - interview

8 Upvotes

Hey there,

I will have an interview for this position (cloud data engineer - strategic cloud engineering) at Google. It's a role that includes both customer-facing responsibilities and coding, but I'd love to get more information :)

First, does anyone know what's the interview process looks like? What kind of technical questions should I expect?

Second, does anyone in that role have some more detailed examples of the daily tasks?

Please feel free to share anything (resources, personal experiences...) that can be useful for preparing and/or understanding more in the detail the role.

Thank you very much!


r/CS_Questions • • Jun 01 '20

You are the interviewer, and I tell you I am the caching expert (SME) at my current job. What questions would you ask me?

8 Upvotes

Grill me. I searched around on some interview websites but would love a personal perspective.


r/CS_Questions • • Mar 11 '20

Do smaller non-FAANG companies ask questions about data structures / system design in interviews or just algorithm type questions?

8 Upvotes

I am currently trying to get better at leedcode everyday.

I currently can solve leetcode easy sort of well depending on the questions subject matter. I also purchased a whiteboard to practice speaking and writing at home out loud. My goal is not to get to FAANG, at least not now. I don't think I am ready yet. My target is probably a small - medium sized tech company, or larger non-tech company.

I can solve leetcode easy problems somewhat well as long as it involves hashMaps, arrays or strings. Once I encounter a data structures like a binary search tree or linked list, I am pretty lost. I think I even ran into a priority queue one which I literally had no idea to solve.

I do know the basic theory behind common data structures like singly / doubly linked list, binary search trees, stacks, queues. However, if asked to implement one on a whiteboard I would really struggle.

Can I expect to be asked questions like :

Given an array A of strings made only from lowercase letters, return a list of all characters that show up in all strings within the list (including duplicates).  For example, if a character occurs 3 times in all strings but not 4 times, you need to include that character three times in the final answer.

You may return the answer in any order.

Example 1:

Input: ["bella","label","roller"]
Output: ["e","l","l"]
Example 2:

Input: ["cool","lock","cook"]
Output: ["c","o"]

and not questions like :

Given a n-ary tree, find its maximum depth.

The maximum depth is the number of nodes along the longest path from the root node down to the farthest leaf node.

Nary-Tree input serialization is represented in their level order traversal, each group of children is separated by the null value (See examples).

Input: root = [1,null,3,2,4,null,5,6]
Output: 3

These are both leetcode easy's. Questions such as the first are much easier for me to solve.

And also, as far as system design questions. Do smaller companies ask these things?

Thank you for any info


r/CS_Questions • • Dec 13 '19

Amazon SDE Virtual interview

8 Upvotes

So after completing the online assessments, I finally got an email saying I'm invited to complete their virtual interviews. I'm a new grad and the email said I would be taking 3 (!!!) 45-minute virtual interviews. I was wondering if this is standard and what everyone's experience was like for this.


r/CS_Questions • • Oct 05 '19

Why does changing variable name in leetcode speed up my code by 25% ?

8 Upvotes

I just answered the question 'Integer Replacement' on leetcode :

"Given a positive integer n and you can do operations as follow:

  1. If n is even, replace n with n/2.

  2. If n is odd, you can replace n with either n + 1or n - 1.

What is the minimum number of replacements needed for n to become 1?"

My code in python :

 def integerReplacement(self, n: int) -> int:
        x = n
        count = 0
        while (x>1):
            count+=1

// if x is even, divide by 2

            if x%2==0:
                x /= 2

// if x is odd, either add 1 or subtract 1, pick which based on which is divisible by a greater power of 2

            else:
                up = x+1
                down = x-1
                while (up%2 == 0 and down%2== 0):
                    up /= 2
                    down /=2
                if (down % 2 == 0 or down == 1):
                    x -= 1
                else:
                    x += 1
        return count

When I change the code to never assign the variable "x=n" and perform all operations on 'n' the code goes from 36 ms to 48 ms. What's going on here ?


r/CS_Questions • • Sep 09 '19

Prep course?

8 Upvotes

Does anyone have any recommendations for a interview prep course? I kind of the need the structure of something like that as well as a place to ask stupid questions...


r/CS_Questions • • Aug 27 '19

Is there a downside to just applying, doing interviews, and learning from the failures?

8 Upvotes

Context: Current student of Applied Math, looking for a CS internship for the coming Fall quarter.

I'm wasting so much time on CTCI and LeetCode style questions... Most of them are just tedious work. I have no way of distilling the problem sets to only the sorts of problems that are insightful, as opposed to based on rote and/or grinding out edge cases. I'm wondering if I will be better off just applying to all sorts of interviews and failing a bunch of times, to get a feel for the process? What are the consequences of failure? Will I get written off by companies like Google for being a return applicant?

Thanks!


r/CS_Questions • • Jun 22 '19

Movie durations on a flight, kinda stumped

8 Upvotes

So, the problem is this, you have a list of movie's in no particular order. You want to find the two movies who have the maximum total runtime that is still equal or less then the duration of your flight. If there is a tie, pick the pair with the single longest movie in it

An O(n2) solution doesn't seem hard to come up with. But I've been stumped on how to make it better, assuming you can. It sounds almost like 2Sum, but because the two movies don't have to exactly equal the flight duration means that O(n) solution won't work. I thought maybe sorting and trying to find some O(nlog(n)) solution, but I haven't really been able to come up with one for that either.

So example: Flight -> 200 minutes

movies: [90, 120, 85, 89, 108]

The answer is the 90 and 108 movies.


r/CS_Questions • • Apr 12 '19

Potential Interview Question help

8 Upvotes

Hello Everyone. I'll make this quick. I am a soon to be CS grad interviewing for a company in SF tomorrow for a role in software. This company is a medical and pharmaceutical distributor, the team that I am a candidate is in charge of an Inventory Management System for the company.

I got word from the recruiter that a potential question would be something along the lines of "What design pattern would you use for an Inventory Management System and why?"

I will be the first to admit I am not incredibly knowledgeable with design patterns. Again, I have not even graduated yet and design patterns are not a big portion of academia. I have mainly been study algorithms and structures.

I came up with the Factory design pattern, here is my explanation. I am going to try and explain it well, while not being to wordy either.

For a management system, we need to keep track of products, their locations, their quantities.

We could create some fundamental abstract class for all products to derive from.

For instance, what does antibiotics, gloves, scalpel, and scissors all have in common? Probably a Product code to denote the individual product, it also has a name, maybe a weight for distributing and packing purposes.  

We specify those attributes are needed in the abstract class and every class that derives from it, now has those attributes. 

We use this abstract class as the basis of all products.  All products implement this class, and can add on attributes and functionality depending on what product it is.  For example, gloves may have a size, where as medicine may have a dosage. 

We have a Factory Manager Class that then controls, and creates the individual products, decides the location of the products, and increases the quantity in that location. 

Let me know what you all think about this answer? Feel free to tell me it is wrong, but please explain why and maybe give me a tip.


r/CS_Questions • • Feb 13 '19

First internship interview tomorrow.

8 Upvotes

Hi, I am a junior level CS student. I landed my first interview for an internship today. A college recruiter from a company I applied for called me for a phone screening. (The position is just an IT internship.) That part went very well, it ended off with the lady telling me she will "certainly be recommending" me to HR. A few hours later, I got another phone call from the company where I scheduled a phone interview with them for tomorrow. They told me a bit more about the position. I asked what kind of phone interview it will be and what I should expect. They told me I will probably be asked some technical questions, previous projects I have worked on, as well as a few behavioral questions as well.

I have never done any personal projects. The only coding I have done is in class assignments, homework problems that required it, and a couple projects I've had in some classes. How can I approach this question since I don't have any personal projects under my belt?

I'm also very worried about any other technical questions that could be asked. I'm not the brightest person in CS. I'm nervous I'm going to choke on this part. How can I prepare myself for any technical questions? Or how can I just approach the technical side of the interview in general if this is a weakness of mine? I can't answer complicated questions off the top of my head, I'm a person who needs to take some time to solve a problem and do research either online or in a textbook when I approach problems.

Any help/advice is greatly appreciated! Thank you!


r/CS_Questions • • Jan 30 '18

Computer Science vs Software Engineering

8 Upvotes

What’s the difference?


r/CS_Questions • • Aug 12 '17

What kind of answer are interviewers looking for when asking "What kind of technologies do you use?"

8 Upvotes

I've been asked this a few times but I don't think they've been impressed with my answers. I haven't had a lot of experience with modern frameworks like React or Angular, but I have had experience with proprietary technology that I'm currently using in my internship.

So, are they looking for answers such as React, Node.js, SQL, etc.?


r/CS_Questions • • Jul 26 '17

New discord community opportunity for mock interviews, programming tips and career advice.

8 Upvotes

Hi, I'm looking to start a new community to help our fellow engineers out. Whether you're starting your first programming course to being retired looking to pass down your knowledge. A while back I set out to give out mock interviews to anyone looking for real feedback. That original post can be found here. Since then I've been receiving messages every day looking for another opportunity to get feedback, asking for help on their resumes and all around tips to get over interview anxiety. So recently I started doing mock interviews again, see this post and this post for my last two streams. All streams happen through https://twitch.tv/twitchlearnsprogramming and have pre-recorded vods. To join the community please join the twitchlearnsprogramming discord channel.

I've been tackling this with a couple of volunteers already but I'm looking to expand out further and give more opportunities to give help to those who want it. This is an opportunity to grow the community of people but as well I need new volunteers to contribute as well. I'm looking for the following roles.

  • Interviewers (To interview people and give real world feedback)

  • Hiring Managers (To give general engineering feedback and along with tips and tricks learned along the way)

  • Recruiters (Anyone who wants to help people with their resumes, general interview process feedback as well as using the platform to recruit some of the members)

  • Admin (People who want to help setup the logistics of streams, interviews and all around planning for the community)

  • Any other suggestions more than welcome

Some of my goals for this community include the following:

  • Real world feedback on their interviewing skills

  • CV review and suggestions

  • Engineering feedback with tips and tricks to help members grow throughout their career

  • Opportunities to speak with real recruiters

  • Provide training resources

  • Provide scholarship and meet up opportunities in the local community and opportunities with different companies (for example the lime scholarship program)

  • Generally help everyone throughout their community, regardless of where they are in their life

This list will grow as the community grows. Please provide any feedback and suggestions for the community.

To join the community please join the twitchlearnsprogramming discord channel.

To watch pre-recorded VODs of prior interviews and to view future streams follow the twitchlearnsprogramming twitch channel.

To volunteer or give any feedback please fill out the google form.

Thanks for all the input and fun so far, let's build a community for everyone.


r/CS_Questions • • Mar 14 '17

The Google Interview: Tips and the process

Thumbnail
blog.ananth.co.in
8 Upvotes

r/CS_Questions • • Feb 28 '17

Can anyone help me understand the solution to this difficult problem?

Post image
8 Upvotes

r/CS_Questions • • Aug 11 '16

How I Improved My Coding Speed In One Week

Thumbnail
blog.gainlo.co
8 Upvotes

r/CS_Questions • • Aug 03 '16

How to prepare for an interview for a front-end developer position

Thumbnail
frontendinsights.com
8 Upvotes

r/CS_Questions • • Mar 15 '16

Whats 7 ways you would test a chair? [interview question]

8 Upvotes

Thursday is my first professional interview for an internship as a test engineer intern. I have heard that this is one of the questions they ask, how would you answer it? Any other advice would be great as well.


r/CS_Questions • • Dec 27 '15

Crappy interview question, but fun!

8 Upvotes

OK, so this one is not a good interview question unless you just want to have fun at the end of the interview, because while it is fun to think about and some interviewees might have good insights, it is hardly relevant to most programming jobs. (Though maybe not all! It's probably a great question for people who are going to be implementing compression algorithms or decoding digital signals.)

Here's the question:

Suppose you and a friend are prisoners, and the prison warden is going to give you one chance to free yourselves. He or she will deal you 5 arbitrary playing cards from a normal 52 card deck. You will be permitted to reveal up to 4 of them to your friend, one by one. Your friend's job is to guess what the last card is. If they get it right, you are both free.

So the question is, can you devise a strategy with your friend that will get you out? Can you get out every time? Can you get out most of the time unless the warden gives you bad cards? Can you guarantee you can get out with some probability?

Some ground rules: You get to reveal cards of your choice one by one, but you cannot communicate anything else. No talking, no side channels, no timing of the cards, nothing like that, just 4 cards and the order they come out.


r/CS_Questions • • Oct 30 '15

How to find pick a random word/line in one-pass, when you don't know how many words/lines exist?

8 Upvotes

I was asked a question recently: Let's say you have a .txt file with a number of lines/words/items. You want to pick out a completely random line. This can certainly be done in two passes: first count and index all the items. Then, you a random number generator to pick a random number: that is your random line! I was asked "how can we do this in ONE step and without knowing how many items exist a priori?" I'm not sure how to do this. Any advice? Is there a particular algorithm to use?


r/CS_Questions • • Sep 09 '15

Anyone have a SD interview with Google? What kind of questions did you face?

8 Upvotes

I'm graduating from college and have an interview with Google. What kind of questions should I be prepared for, aside from data structures?


r/CS_Questions • • Nov 14 '11

Find the exact node in a linked list where a cycle begins.

8 Upvotes

You are given a singly linked list which may or may not contain a cycle. You are to find the exact node in which the cycle first appears. If there is no cycle, return -1.

Example:

A->B->C->D->E->F->G->D

Return D


r/CS_Questions • • Nov 13 '11

Classic Interview Question: Lowest Common Ancestor

8 Upvotes

Given any two nodes in a rooted tree find the lowest common ancestor (LCA) of those two nodes (that is, a the common ancestor of those nodes that is lowest down in the tree). Do not assume you have a binary search tree and nodes may (or may not) have more than two child nodes in any order. Nodes also do have references to their parents. Your solution should be able to run in O(h) time, where h is the height of the tree.

For the examples we'll use the following tree:

       1
     /   \
    2     3
   / \   / \
  4   5 6   7
 / \
8   9

Given any two nodes that share the same parent (e.g., 2 and 3, 4 and 5, 6 and 7, or 8 and 9) the LCA is just their parent.

Given any two nodes where one node is a child of the other (the other being the parent of the first), the LCA is the parent node. So given nodes 4 and 2, for example, the LCA is 2.

Given nodes 4 and 6, the LCA is 1.

Given nodes 8 and 5, the LCA is 2.

Extra Credit:

Modify your algorithm to accept any number of nodes and find their LCA. This should run in O(hk) time, where k is the number of nodes you are checking.

 
 
 
 
 
 
 

A solution for the non-extra credit part in case you couldn't get it and you wanted to attempt to extend it for the extra credit: see here.

This is a new subreddit so I feel like the rules are still being stamped out. If posting (one of) the solution(s) in the original post is not ok, just let me know and I'll remove it. Some people have custom CSS turned off, so I moved the solution to pastebin.


r/CS_Questions • • Oct 18 '23

What's your take on bots in blockchain?

7 Upvotes

They're like the unsung heroes and the villains all rolled into one. Here's what's on my mind:

Blockchain bots can be real game-changers. They can automate transactions, help with trading, and provide liquidity in decentralized exchanges. Bots like market-making bots contribute to liquidity, making the crypto market more efficient. For example, NeuroChain is powered by an ecosystem of smart, fast, secure Bots that learn, evolve, and get smarter through interaction and activity. Ultimately, they will autonomously resolve issues and propose solutions.

But, there's a dark side too. In trading, some bots manipulate the market, leading to pump-and-dump schemes and price volatility. They can also facilitate fraudulent activities like front-running and spoofing. So, there's a lot of room for mischief.

Then there are those bots we don't even know about. In DeFi, for instance, flash loan attacks and rug pulls are often orchestrated by bots. These incidents can be pretty devastating for investors.

So, what's your take on bots in blockchain? Have you had any run-ins, good or bad, with them? Do you think the benefits outweigh the risks, or is it the other way around?


r/CS_Questions • • Jun 13 '23

Tips for staff engineer presentation

7 Upvotes

I think I almost cleared DataDog interview. Before starting the new interview, HR had told me that seniority of the position will be determined based on interview performance. At the end of all interviews, I got to meet the HR and I conveyed that all interviews went really well and I am expected to be offered as staff engineer position. She told me that it is very difficult to hire someone at staff+ level. It needs certain level of approvals and if approved by senior hiring committee, I will need to give some kind of presentation to them. Any insights or tips on how to navigate the situation? HR has informed me that she will get back to me with either an offer or a decision if committee agreed for staff level presentation.