Two Sum - LeetCode EasyProblem Link - https://leetcode.com/problems/two-sum/ class Solution { public: vector<int> twoSum(vector<int>& nums, int target) { int n=nums.size(); //finding the length of the dynamic array i.e., our vector unordered_map<int,int...Jul 14, 2022 · 1 min readrajattiwari.hashnode.dev
Introduction to Computer NetworkWhat is Computer Network? A computer network is a collection of various computing devices that are connected using multiple paths for the purpose of sending/recieving data or media. A sender send a data to the reciever while both sender i.e, client a...Jun 19, 2022 · 2 min readrajattiwari.hashnode.dev
How to grow 1% Everyday?Rule of 1.01 1.01 ^ 365 = 37.8 Everyday do a little to grow and atleast try to do. Here are 5 ways to grow 1% daily. 1. Fail more, Fail fast & Fail big: If we Fail more often, fail faster, fail bigger, we learn more & grow more. I used to avoid fai...Apr 20, 2021 · 2 min readrajattiwari.hashnode.dev
Reverse Integer - Leetcode SolutionSo, the problem statement is: Given a signed 32-bit integer x, return x with its digits reversed. If reversing x causes the value to go outside the signed 32-bit integer range [-231, 231 - 1], then return 0. The solution is in python. class Solutio...Mar 20, 2021 · 1 min readrajattiwari.hashnode.dev
Two Sum - Leet Code SolutionSo, the problem statement was: Given an array of integers nums and an integer target, return indices of the two numbers such that they add up to target. You may assume that each input would have exactly one solution, and you may not use the same elem...Mar 20, 2021 · 2 min readrajattiwari.hashnode.dev