Research portable Memory game | Исследовать портируемую игру Память
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
410B

  1. #include <stdio.h>
  2. #include "utarray.h"
  3. int main()
  4. {
  5. UT_array *nums;
  6. long l, *p;
  7. UT_icd long_icd = {sizeof(long), NULL, NULL, NULL };
  8. utarray_new(nums, &long_icd);
  9. l=1;
  10. utarray_push_back(nums, &l);
  11. l=2;
  12. utarray_push_back(nums, &l);
  13. p=NULL;
  14. while( (p=(long*)utarray_next(nums,p)) != NULL ) {
  15. printf("%ld\n", *p);
  16. }
  17. utarray_free(nums);
  18. return 0;
  19. }