adding python solution