kunal-kushwaha / DSA-Bootcamp-Java

This repository consists of the code samples, assignments, and notes for the Java data structures & algorithms + interview preparation bootcamp of WeMakeDevs.
https://www.youtube.com/playlist?list=PL9gnSGHSqcnr_DxHsP7AW9ftq0AtAyYqJ
17.25k stars 11.08k forks source link

Update PowOfTwo.java #1023

Open PriyankaSep04 opened 1 year ago

PriyankaSep04 commented 1 year ago

Fixed for n<=0 as negative numbers and 0 can't be power of 2.