almost done
implemented