Most of this code was created by myself, when I am leanring program language