Thanks, I figured the problem was bad arduino IDE. Tried on different computer and all worked.
Thanks