Changeset db87a35 for tests/algorithms/range_test.cfa
- Timestamp:
- Dec 3, 2021, 3:33:02 PM (3 years ago)
- Branches:
- ADT, ast-experimental, enum, forall-pointer-decay, master, pthread-emulation, qualifiedEnum
- Children:
- 4c26a94
- Parents:
- 8e658241
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tests/algorithms/range_test.cfa
r8e658241 rdb87a35 17 17 #include <algorithms/range_iterator.hfa> 18 18 19 void print(const char * range){ 20 RangeIter r = { range }; 21 while(moveNext(r)) { 22 sout | r.com | nonl; 23 } 24 sout | nl; 25 } 26 19 27 int main() { 20 { 21 RangeIter r = { "0-6" }; 22 while(moveNext(r)) { 23 sout | r.com | nonl; 24 } 25 sout | nl; 26 } 28 print("0-6"); 29 print("0"); 30 print("0-6,22-30"); 31 print("0,2,4,6,8,10"); 32 print("0-6,8-14,16,32"); 33 print("0-4,6,8-12,14,16-20"); 27 34 }
Note: See TracChangeset
for help on using the changeset viewer.