use generic float logic
fix case sensitivity issue
add missing headers
fix random code generator