Added checks for double words