copilotsingleton pattern GeeksforGeeks - Search