First Coded Working Version