* window now takes double
* window takes input from array
* better output