updated code  format