Guest User

Untitled

a guest
Jul 16th, 2018
93
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.51 KB | None | 0 0
  1. data list list/dog cat mouse frog bird (5f1).
  2. begin data
  3. 1 0 0 1 0
  4. 0 1 0 1 0
  5. 0 0 0 1 1
  6. 0 1 0 0 0
  7. 1 1 1 1 1
  8. 1 0 1 0 1
  9. 0 0 0 0 0
  10. end data.
  11.  
  12. compute mult_categoryN = 10000*dog + 1000* cat +100*mouse +10* frog + bird.
  13.  
  14. string mult_categoryT (a50).
  15. compute #=0.
  16. do repeat vr=dog cat mouse frog bird/ct="dog" "cat" "mouse" "frog" "bird".
  17. do if vr=1.
  18. if #=0 mult_categoryT=ct.
  19. if #>0 mult_categoryT=concat(rtrim(mult_categoryT), " and ", ct).
  20. compute #=#+1.
  21. end if.
  22. end repeat.
  23. exe.
Add Comment
Please, Sign In to add comment