Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MATRIX SEARCH #89

Open
akshitagupta15june opened this issue Sep 26, 2020 · 8 comments
Open

MATRIX SEARCH #89

akshitagupta15june opened this issue Sep 26, 2020 · 8 comments

Comments

@akshitagupta15june
Copy link
Member

STAR THIS REPO!

Given an n x m matrix, where every row and column is sorted in increasing order, and a number x . Find if element x is present in the matrix or not.

Input Format

First line consists of two space separated integers N and M, denoting the number of element in a row and column respectively. Second line of each test case consists of N*M space separated integers denoting the elements in the matrix in row major order. Third line of each test case contains a single integer x, the element to be searched.
Constraints

1 <= N,M <= 30 0 <= A[i] <= 100000

Output Format

Print 1 if the element is present in the matrix, else 0.

Sample Input

3 3
3 30 38
44 52 54
57 60 69

62

Sample Output

0

@akshitagupta15june
Copy link
Member Author

akshitagupta15june commented Sep 26, 2020

ADD IN SEARCHING SORTING REPO

@sagarr70
Copy link

can you assign this to me as a part of hacktoberfest 2020

@akshitagupta15june
Copy link
Member Author

ok

@tausiq2003
Copy link

should I contribute

@shubhcoder2104
Copy link
Member

Yes you can

@tausiq2003
Copy link

i will contribute for hacktoberfest 2021. So please accept

@tausiq2003
Copy link

please assign me

@AvinashDwivedi
Copy link
Contributor

Hello Akshita, hope everything is good.
If this one is still available then please assign it to me, I'll finish this in few hrs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants