GeeksforGeeks
17.4K subscribers
1.83K photos
34 videos
24 files
2.76K links
Official Hub βœ…

Your coding haven – where tech meets simplicity.

Discover:
πŸ˜‚ Coding Laughter
πŸ“˜ Curated Study Material
πŸ’Ž Exclusive Offers

Utilize every service we provide and make a promise to find better opportunities for yourself! #gfgkarlohojayega!
Download Telegram
Bringing you another set of opportunities to add vibrance to your journey of success. Gear up! Your skills will speak up here.πŸ˜€πŸ€Œ

This is Job-A-Thon 21 🎊

Embrace your future with the best opportunitiesπŸ™Œβœ¨

Register here: https://bit.ly/3qCSKjS
Problem Of The Day
"Next Smallest Palindrome"

Given a number, in the form of an array Num[] of size N containing digits from 1 to 9(inclusive). The task is to find the next smallest palindrome strictly larger than the given number.

Example 1:

Input:
N = 11
Num[] = {9, 4, 1, 8, 7, 9, 7, 8, 3, 2, 2}
Output: 9 4 1 8 8 0 8 8 1 4 9
Explanation: Next smallest palindrome is
94188088149.

Example 2:

Input:
N = 5
Num[] = {2, 3, 5, 4, 5}
Output: 2 3 6 3 2
Explanation: Next smallest palindrome is
23632.

Your Task:
Complete the function generateNextPalindrome() which takes an array num, and an single integer n, as input parameters and returns an array of integers denoting the answer. You don't to print answer or take inputs.

Expected Time Complexity: O(N)
Expected Auxiliary Space: O(1)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/next-smallest-palindrome4740/1
πŸ‘2
🚨 Job Alert 🚨
Media.net is hiring for Research Analyst.

Location - Mumbai
Experience - Internship + PPO
Apply by - Aug 23, 2023

Apply via the following link and share the opportunity with your friends - https://practice.geeksforgeeks.org/jobs/medianet-research-jobathon?utm_source=telegram&utm_medium=marketingteam_gfgmain&utm_campaign=medianetresearchjobathon

Register for Job-A-Thon - https://bit.ly/3qCSKjS
Java is one of the highly robust and high-level programming languages. It is one of the most powerful programming languages currently used in over 3 billion devices.

It is currently being used by top tech giants like Amazon, Adobe, Instagram, Flipkart, and a lot more. So learning this technology offers amazing salaries, global recognition, and great growth opportunities.

This article will discuss the top 7 Java certifications for developers that will surely enhance your career.

Link- https://bit.ly/45bNSBv
Hola Geeks!
Put your skills on test with Cloud Bootcamp.

Solve a series of puzzles and stand a chance to win exciting rewards.

40 minutes πŸ‘‰ 10 puzzles πŸ‘‰ Title of Google Cloud Riddler

Starting tomorrow onwards!

So, head to our Discord server now - https://discord.gg/UYV8E5PDnV
Problem Of The Day
"Leaders in an array"

Given an array A of positive integers. Your task is to find the leaders in the array. An element of array is leader if it is greater than or equal to all the elements to its right side. The rightmost element is always a leader.

Example 1:

Input:
n = 6
A[] = {16,17,4,3,5,2}
Output: 17 5 2
Explanation: The first leader is 17
as it is greater than all the elements
to its right. Similarly, the next
leader is 5. The right most element
is always a leader so it is also
included.

Example 2:

Input:
n = 5
A[] = {1,2,3,4,0}
Output: 4 0
Explanation: 0 is the rightmost element
and 4 is the only element which is greater
than all the elements to its right.

Your Task:
You don't need to read input or print anything. The task is to complete the function leader() which takes array A and n as input parameters and returns an array of leaders in order of their appearance.

Expected Time Complexity: O(n)
Expected Auxiliary Space: O(n)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/leaders-in-an-array-1587115620/1
πŸ‘4
🚨 Job Alert 🚨
iSource is hiring for Dot Net Developer.

Location - New Delhi
Experience - Internship
Apply by - Aug 23, 2023

Apply via the following link and share the opportunity with your friends - https://bit.ly/3YD24AU

Register for Job-A-Thon - https://bit.ly/3qCSKjS
πŸ‘1
Must Learn!πŸ’‘
The debate on Full Stack Development Vs. Data Science: Which one to Choose? is continuing. Both have their advantages and require skills to get into it.

But, do you know the proper way to get into it, or which field interests you more? In this blog, we’ll be talking about the skills required, the salary offered, and career growth in each domain.

Link- https://bit.ly/3P155aV
πŸ‘1
🚨 Job Alert 🚨
RechargeKit is hiring for DevOps Engineer.

Location - Bhubaneswar, Odisha
Experience - 1 - 2 Years
Apply by - Aug 23, 2023

Apply via the following link and share the opportunity with your friends - https://bit.ly/3E1PHVy

Register for Job-A-Thon - https://bit.ly/3qCSKjS
The 116th edition of the GFG Weekly Coding Contest has entered the room. πŸ™Œ

Upskill, because career advancement begins here!πŸ˜ƒ

So, we are back with GFG Weekly Coding Contest to help you become a proficient coder.😎

So, register now - https://bit.ly/3qAkhm6
Problem Of The Day
"Subarray with given sum"

Given an unsorted array A of size N that contains only positive integers, find a continuous sub-array that adds to a given number S and return the left and right index(1-based indexing) of that subarray.

In case of multiple subarrays, return the subarray indexes which come first on moving from left to right.

Note:- You have to return an ArrayList consisting of two elements left and right. In case no such subarray exists return an array consisting of element -1.

Example 1:

Input:
N = 5, S = 12
A[] = {1,2,3,7,5}
Output: 2 4
Explanation: The sum of elements
from 2nd position to 4th position
is 12.

Example 2:

Input:
N = 10, S = 15
A[] = {1,2,3,4,5,6,7,8,9,10}
Output: 1 5
Explanation: The sum of elements
from 1st position to 5th position
is 15.

Your Task:
You don't need to read input or print anything. The task is to complete the function subarraySum() which takes arr, N, and S as input parameters and returns an ArrayList containing the starting and ending positions of the first such occurring subarray from the left where sum equals to S. The two indexes in the array should be according to 1-based indexing. If no such subarray is found, return an array consisting of only one element that is -1.

Expected Time Complexity: O(N)
Expected Auxiliary Space: O(1)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/subarray-with-given-sum-1587115621/1
πŸ‘4
Must Learn! πŸ’‘
Usually, you may have seen error 403 while accessing a web page from your web browser. Furthermore, error 403 signifies that a client doesn’t have the required permissions to access the resources.

Sometimes, developers disable directory browsing so third parties cannot access important files on their websites.

So if you also face the HTTP 403 error and don’t know how to resolve it, this tutorial is for you. Here we will explain What is 403 Not Found Error and How to Fix It quickly.

Link - https://bit.ly/3qK7ptD
Problem Of The Day
"Number of occurrence"

Given a sorted array Arr of size N and a number X, you need to find the number of occurrences of X in Arr.

Example 1:

Input:
N = 7, X = 2
Arr[] = {1, 1, 2, 2, 2, 2, 3}
Output: 4
Explanation: 2 occurs 4 times in the
given array.

Example 2:

Input:
N = 7, X = 4
Arr[] = {1, 1, 2, 2, 2, 2, 3}
Output: 0
Explanation: 4 is not present in the
given array.

Your Task:
You don't need to read input or print anything. Your task is to complete the function count() which takes the array of integers arr, n, and x as parameters and returns an integer denoting the answer.
If x is not present in the array (arr) then return 0.

Expected Time Complexity: O(logN)
Expected Auxiliary Space: O(1)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/number-of-occurrence2259/1
πŸ‘2
Must Learn! πŸ’‘
Mobile application development industries play a major role in today’s generation as many businesses are looking forward to building a mobile application for their enterprise.

A developed application needs to be published on Google Play Store for the intended audience to download and use it.

Learn more- https://bit.ly/3YFwClC
Problem Of The Day
"Surround the 1's"

Given a matrix of order nxm, composed of only 0's and 1's, find the number of 1's in the matrix that are surrounded by an even number (>0) of 0's. The surrounding of a cell in the matrix is defined as the elements above, below, on left, on right as well as the 4 diagonal elements around the cell of the matrix. Hence, the surrounding of any matrix elements is composed of 8 elements. Find the number of such 1's.

Example 1:

Input:
matrix = {{1, 0, 0},
{1, 1, 0},
{0, 1, 0}}
Output:
1
Explanation:
1 that occurs in the 1st row and 1st column, has 3 surrounding elements 0,1 and 1. The occurrence of zero is odd.
1 that occurs in 2nd row and 1st column has 5 surrounding elements 1,0,1,1 and 0. The occurrence of zero is even.
1 that occurs in 2nd row and 2nd column has 8 surrounding elements. The occurrence of 0 is odd.
Similarly, for the 1 that occurs in 3rd row and 2nd column, the occurrence of zero in it's 5 surrounding elements is odd.
Hence, the output is 1.

Example 2:

Input:
matrix = {{1}}
Output:
0
Explanation:
There is only 1 element in the matrix. Hence, it has no surroundings, so it's count for even 0's is 0 for the whole matrix.
0 is even but we want occurrence of a zero in the surrounding at least once.
Hence, output is 0.

Your Task:
You don't need to read or print anything. Your task is to complete the function Count() which takes the matrix as input parameter and returns the number of 1's which are surrounded by even number of 0's.

Expected Time Complexity: O(n * m)
Expected Space Complexity: O(1)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/surround-the-1s2505/1
πŸ‘1
🚨 Job Alert 🚨
RechargeKit is hiring for System Operations Engineer.

Location - Bhubaneswar, Odisha
Experience - 1 - 3 Years
Apply by - Aug 23, 2023

Apply via the following link and share the opportunity with your friends - https://bit.ly/3KMrJkO

Register for Job-A-Thon - https://bit.ly/3qCSKjS
🚨 Job Alert 🚨
Hummingbird Web Solutions is hiring for Javascript developer.

Location - Pune, Maharashtra
Experience - Fresher
Apply by - Aug 23, 2023

Apply via the following link and share the opportunity with your friends - https://bit.ly/44i95bD

Register for Job-A-Thon - https://bit.ly/3qCSKjS
😁1
Must Learn! πŸ’‘
Indeed, appropriate skills and knowledge are more important than any college degree for any organization. However, demanding a college degree from employers also makes sense as it is easy to assume that a candidate with a college degree would be proficient with the required skills as per the curriculum.

Still, in the present-day’s scenario, a person may end up more qualified and skilled than a person with a degree due to various advancements such as boot camps, corporate training, e-learning, etc. Now, let’s take a look at those top companies that don’t require candidates to have a college degree.

Link- https://bit.ly/3OMlVZM
πŸ‘3
Problem Of The Day
"Make Matrix Beautiful"

A beautiful matrix is a matrix in which the sum of elements in each row and column is equal. Given a square matrix of size NxN. Find the minimum number of operation(s) that are required to make the matrix beautiful. In one operation you can increment the value of any one cell by 1.

Example 1:

Input:
N = 2
matrix[][] = {{1, 2},
{3, 4}}
Output:
4
Explanation:
Updated matrix:
4 3
3 4
1. Increment value of cell(0, 0) by 3
2. Increment value of cell(0, 1) by 1
Hence total 4 operation are required.

Example 2:

Input:
N = 3
matrix[][] = {{1, 2, 3},
{4, 2, 3},
{3, 2, 1}}
Output:
6
Explanation:
Number of operations applied on each cell are as follows:
1 2 0
0 0 0
0 1 2
Such that all rows and columns have sum of 9.

Your Task:
You don't need to read input or print anything. Complete the function findMinOpeartion() that takes matrix and n as input parameters and returns the minimum number of operations.

Expected Time Complexity: O(N * N)
Expected Auxiliary Space: O(N)

Solve and submit your answer here : https://practice.geeksforgeeks.org/problems/make-matrix-beautiful-1587115620/1
πŸ‘2
Must Learn!πŸ’‘
The process of retrieving and restoring lost, corrupted, inaccessible, damaged, or accidentally deleted data is called data recovery. It is a software-driven process.

The following are the best Data Recovery Software for Windows. We have briefed down the features, versions, and payment of each software tool.

Link- https://bit.ly/47EMwAO
πŸ‘6