IMP : Tried to implement thread, it did not work well