Day 92/100: The task is to cover all zeros in a binary matrix. For each zero, check if there is value one present in any of the four adjacent positions (left, right, top, or bottom). If one is present, increment the count. #100dayscodechallenge
Swathi V’s Post
More Relevant Posts
-
Day 35/100: Find the missing number in an array containing distinct elements from 1 to N. #100dayscodechallenge
To view or add a comment, sign in
-
This video focuses on a part of C# that we all probably just do on auto-drive, although are we using them correctly... and do you know the limitations to the access that is protected?
Peek-a-Boo with C#: Uncovering Access Modifiers!
https://www.youtube.com/
To view or add a comment, sign in
-
#100daysofcode of day 10. This C++ program defines a Triangle class with private member variables representing the lengths of its sides. It provides member functions to determine whether the triangle is equilateral, isosceles, or scalene. The main function prompts the user to input the lengths of the triangle's sides, creates a Triangle object, and outputs the type of triangle based on its properties.
To view or add a comment, sign in
-
#day138 of #365daysofcodechallenge Entering into Class and Objects Topics Problem: Class Matrix Below Image describes : Problem Description, Problem Constraints, solution
To view or add a comment, sign in
-
✅leetcode:104 Approach: we have to traverse on each node because the longest path will be the max height of the tree, That is why we will go on each possible node the formula we are using is 1 + max(leftHeight, rightHeight): here 1 is added for the root node. 🧑💻Time complexity: O(n) where n is number of nodes in a binary tree. #dsa #dailycoding #striversa2zdsa #binarytree
To view or add a comment, sign in
-
#day135 of #365daysofcodechallenge Entering into Class and Objects Topics Problem: Class Circle Below Image describes : Problem Description, Problem Constraints, solution
To view or add a comment, sign in
-
Today was good. Did 15 commits, and improved lot of my container libraries. Also I implemented an automatic code to convert C++ templates to explicit instantiated structs. Also, I stopped using capital letters for a few key macros. For example: Instead of MY_ASSERT(code, message), I'm using myAssert(code, message) myAssert(code, message) feels less annoying to read. #aerospace #cfd
To view or add a comment, sign in
-
Top 20% @LeetCode(1600+ rating) |GGSIPU Topper BCA 2024 | Maharaja Surajmal Institute 2026 | C++ DSA | GGSOC'24
NAME OF THE PROBLEM : Minimum Bits Split to convert Number A bit flip of a number x is choosing a bit in the binary representation of x and flipping it from either 0 to 1 or 1 to 0. For example, for x = 7, the binary representation is 111 and we may choose any bit (including any leading zeros not shown) and flip it. We can flip the first bit from the right to get 110, flip the second bit from the right to get 101, flip the fifth bit from the right (a leading zero) to get 10111, etc. Given two integers start and goal, return the minimum number of bit flips to convert start to goal. SOLUTION LINK : [https://lnkd.in/gv-ci7Vb]
To view or add a comment, sign in
-
30/30 #30DaysOfCode✅️ Today Done a problem on Arrays called "Find Peak Element".It's a medium problem with good number of test cases which make me to think in way out of box. At starting I thought this is a pretty easy problem Difficulty level:Medium
To view or add a comment, sign in
-
Electronics and communication engineering major with strong coding and development skills for a software engineering full time role.
📢 Day 54 of #75daysdsachallenge 🚀 Problem: Write a function that takes the binary representation of a positive integer and returns the number of set bits it has (also known as the Hamming weight). Solution:
To view or add a comment, sign in