Open in app

Sign in

Write

Sign in

S SATHISH BABU
S SATHISH BABU

60 Followers

Home

About

Published in

Dev Genius

·Jun 12, 2022

Leetcode Contest 297

Problem 1 Calculate Amount Paid in Taxes You are given a 0-indexed 2D integer array brackets where brackets[i] = [upperi, percenti] means that the ith tax bracket has an upper bound of upperi and is taxed at a rate of percenti. The brackets are sorted by upper bound (i.e. …

Competitive Programming

5 min read

Leetcode Contest 297
Leetcode Contest 297
Competitive Programming

5 min read


Published in

Dev Genius

·Jun 5, 2022

Leetcode Contest 296

Problem 1 Min Max Game You are given a 0-indexed integer array nums whose length is a power of 2. Apply the following algorithm on nums: Let n be the length of nums. If n == 1, end the process. Otherwise, create a new 0-indexed integer array newNums of length n / 2. For every…

Competitive Programming

4 min read

Leetcode Contest 296
Leetcode Contest 296
Competitive Programming

4 min read


Published in

Dev Genius

·Mar 26, 2022

Dealing with Exceptions in Python

Dealing with exceptions in python is straightforward. You would surround your code with try-catch blocks. The exception message to be captured/processed will be mentioned as a variable in the except block. 1. Catching Exceptions Let’s assume this is our block of code def fun(): try…

Python

2 min read

Dealing with Exceptions in Python
Dealing with Exceptions in Python
Python

2 min read


Published in

Dev Genius

·Mar 26, 2022

RabbitMQ

In the recent projects I’ve worked on, we decided to move on the direction of a microservice architecture pattern. The motivation behind such a move was to overcome the difficulties faced in the monolith architecture and based on our requirements as well. RabbitMQ is a component on which we heavily…

Rabbitmq

5 min read

RabbitMQ
RabbitMQ
Rabbitmq

5 min read


Jul 10, 2021

Multiple git accounts in one machine

Sometimes we would require to handle multiple git accounts say a personal one and one associated with work. It can become frustrating to switch between accounts while committing or pushing any changes. Changing names manually One way to tackle this is to set the name and email before committing the changes. git config…

Git

2 min read

Multiple git accounts in one machine
Multiple git accounts in one machine
Git

2 min read


Jan 19, 2021

Daily Coding Problem: Problem #10

Here I am with another problem! Problem Implement a job scheduler which takes in a function f and an integer n, and calls f after n milliseconds. Solution1: Direct implementation The straightforward approach will be to write a function that takes a function and an integer as arguments, that waits for n milliseconds and…

Python

2 min read

Daily Coding Problem: Problem #10
Daily Coding Problem: Problem #10
Python

2 min read


Jan 13, 2021

Daily Coding Problem: Problem #6

Problem This problem was asked by Google. An XOR linked list is a more memory efficient doubly linked list. Instead of each node holding next and prev fields, it holds a field named both, which is an XOR of the next node and the previous node. …

Python

2 min read

Daily Coding Problem: Problem #6
Daily Coding Problem: Problem #6
Python

2 min read


Jan 13, 2021

Daily Coding Problem: Problem #5

Problem This problem was asked by Jane Street. cons(a, b) constructs a pair, and car(pair) and cdr(pair) returns the first and last element of that pair. For example, car(cons(3, 4)) returns 3, and cdr(cons(3, 4)) returns 4. Given this implementation of cons: def cons(a, b): def pair(f): return f(a, b) return…

Python

1 min read

Daily Coding Problem: Problem #5
Daily Coding Problem: Problem #5
Python

1 min read


Published in

Dev Genius

·Aug 13, 2020

Daily Coding Problem: Problem #12

Here I am with another problem! Problem There exists a staircase with N steps, and you can climb up either 1 or 2 steps at a time. Given N, write a function that returns the number of unique ways you can climb the staircase. The order of the steps matters. For…

Python

3 min read

Daily Coding Problem: Problem #12
Daily Coding Problem: Problem #12
Python

3 min read


Published in

Dev Genius

·Jul 20, 2020

Daily Coding Problem: Problem #11

Here I am with another problem!. Problem Implement an autocomplete system. That is, given a query string s and a set of all possible query strings, return all strings in the set that have s as a prefix. For example, given the query string de and the set of strings [dog, deer, deal], return [deer, deal]. Hint: Try pre-processing the dictionary into a more efficient data structure to speed up queries.

Python

1 min read

Daily Coding Problem: Problem #11
Daily Coding Problem: Problem #11
Python

1 min read

S SATHISH BABU

S SATHISH BABU

60 Followers

Software Engineer @ Google

Following
  • Netflix Technology Blog

    Netflix Technology Blog

  • Martin Heinz

    Martin Heinz

  • Fasih Khatib

    Fasih Khatib

  • Rodney James

    Rodney James

See all (12)

Help

Status

About

Careers

Blog

Privacy

Terms

Text to speech

Teams