Husen's Code
Here I will share my source code
Reverse an array arr[] = {a, b, c, .......}; # include < iostream > int reverse ( int arr [], int size ) { …
Read more----Naive approach---- # include < iostream > bool ifsorted ( int arr [], int size ) { for ( int i …
Read moreNaive approach # include < iostream > // naive solution 2 times traversal of the array; int getlargest ( int …
Read more#include <iostream> int getlargest(int arr[], int n) { int res = 0; for (int i = 1; i < n; i++) { if…
Read moreCheck for k th bit; I have solved the problem in two ways 1] Using left shift operator (<<); 2] Using right shif…
Read moreComputing Power in c++ powerof(x , n) This function takes log(n) time and auxilury space is big O 1; #include <ios…
Read morePrinting divisor in c++ I wrote the program to print all the divisors of a number... #include <iostream> #includ…
Read more
Social Plugin