ankitapuri / DSA-guide

Trying to cover important DSA
MIT License
49 stars 114 forks source link

[feature-1] Added Staircase Search in CPP #263

Closed kiruba-r11 closed 3 years ago

kiruba-r11 commented 3 years ago

Related Issues

Closes: #262

Describe the changes you've made

I have completely implemented a CPP program that takes the input of the row and column sorted matrix and a key and performs the types of search to find the key in the matrix. All the three searching types, exploit the property of row and column sorted elements of the matrix and optimizes the problem.

Type of change

How Has This Been Tested?

This has been tested by generating a set of random inputs using a generator and verified the outputs manually.

Describe if there is any unusual behavior of your code(Write NA if there isn't)

NA

Checklist:

kiruba-r11 commented 3 years ago

@ankitapuri Please have a look at it

kiruba-r11 commented 3 years ago

@ankitapuri It's because the problem is solved in three different complexities and is printing the results. It is just to verify that all three approaches provide same output.

ankitapuri commented 3 years ago

Just separate the results in output as well by providing the complexities

kiruba-r11 commented 3 years ago

@ankitapuri Please have a look at it.