Learnt about type-punning. Used a union to work around it.