How can I achieve this behavior?
enum week { sunday=0, monday, tuesday, wednesday, thursday, friday, saturday };
enum week day = saturday; // 6 // ++day => 0
enum week day = sunday; // 0 // --day => 6
Aucun commentaire:
Enregistrer un commentaire