#dsa
Read more stories on Hashnode
Articles with this tag
Sum of Series Sum of Series | Practice | GeeksforGeeks Write a program to find the sum of the given series 1+2+3+ . . . . . .(N terms) Example 1:...
Minimize the Heights II Given an array arr[] denoting heights of N towers and a positive integer K. For each tower, you must perform exactly one of...
Cyclically rotate an array by one Given an array, rotate the array by one position in clock-wise direction. Example 1: Input: N = 5 A[] = {1, 2, 3,...
Union of two arrays Given two arrays a[] and b[] of size n and m respectively. The task is to find the number of elements in the union between these...
Move all negative elements to end Given an unsorted array arr[] of size n having both negative and positive integers. The task is place all negative...
Reverse a String Given a String S , print the reverse of the string as output. class Solution { public: string revStr(string S) { ...