Used in Binary Search algorithm
Used in Merge sort algorithm.
Initialize 2D array
Difference between i++ and ++i
So basically ++i returns the value after it is incremented, while i++ return the value before it is incremented.
Right Shift x»y
Moving bit/s towards the right side in binary number.
4>>2 = 16
x/2^y divide x by 2 to the power of y.
Left Shift x«y
Moving bit/s towards the left side in binary number.
4<<2 = 0
x*2^y multiply x by 2 to the power of y.
Thanks for reading my article till end. I hope you learned something special today. If you enjoyed this article then please share to your friends and if you have suggestions or thoughts to share with me then please write in the comment box.
Founder of Fullstack Master