m = peripheral.wrap("top")
while true do
m.setBackgroundColor(colors.black)
m.clear()
local time = os.time()
--local formattedTime = textutils.formatTime(time, false)

if time > 6 or time < 19 then
m.setCursorPos(1,1)
m.write("TIME: DAY") 
end

if time < 6 or time > 19 then
m.setCursorPos(1,1)
m.write("TIME: NIGHT")
end

sleep(1)
end
