Using Json List Python Functions With Variable Number