modified by roy
first try done