C examples mimic Python examples