<s>[INST] This problem is from edabit and is as follows:

"Create a function that takes a number of hours and minutes as arguments. The function should return a string that represents the given time in 12-hour format (e.g. "10:45 PM" or "3:15 AM")."

I solved it as follows:

```python
def time_of_day(hours, minutes):
    periods = ["AM", "PM"]
    am_hours = hours % 12
    if am_hours == 0:
        am_hours = 12
    return f"{am_hours}:{minutes:02d} {periods[hours//12]}"

print(time_of_day(22, 45))
```
It prints out "10:45 PM" which is correct.

However I'm only scoring 80% on this problem. What is the solution to achieve the 100% mark?[/INST]