Project pool

BeginnerHTML · CSS · JavaScript

Bill splitter

Split a bill between friends, with a tip, as you type.

Time
~4h
When approved
+100 XP

The brief

Enter the bill, the tip percentage and the number of people; see what each person pays. Everything updates as you type, with no button.

What must work

  • 01Inputs for bill, tip (preset buttons and a custom value) and people
  • 02Shows tip per person and total per person, updating as you type
  • 03Handles bad input: no negative numbers, no dividing by zero people
  • 04Labels on every input, usable with a keyboard only

If you want to go further

  • Remember the last tip used with localStorage
  • Round up to the nearest ₦50