Advertisement
Guest User

Untitled

a guest
Jan 16th, 2018
90
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. Inputs:
  2.  
  3. abc def 123 74 hike bleh
  4. def 123 75 129 deb bla
  5.  
  6. Outputs:
  7.  
  8. Enter the string elements of A separated by space :
  9. abc def 123 74 hike bleh
  10. Enter the string elements of B separated by space :
  11. def 123 75 129 deb bla
  12.  
  13. 1. The cardinality and roster of the intersection of A and B
  14. def 123
  15. Total 2 entries
  16.  
  17. 2. The cardinality and roster of the union of A and B
  18. abc def 123 74 hike bleh 75 129 deb bla
  19. Total 10 entries
  20.  
  21. 3. The cardinality and roster of the relative complement of A and B
  22. abc 74 hike bleh
  23. Total 4 entries
  24.  
  25. 4. The cardinality and roster of the relative complement of B and B
  26. 75 129 deb bla
  27. Total 4 entries
  28.  
  29. 5. The cardinality and roster of the cross product of A and B
  30. (abc x def) (abc x 123) (abc x 75) (abc x 129) (abc x deb) (abc x bla) (def x def) (def x 123) (def x 75) (def x 129) (def x deb) (def x bla) (123 x def) (123 x 123) (123 x 75) (123 x 129) (123 x deb) (123 x bla) (74 x def) (74 x 123) (74 x 75) (74 x 129) (74 x deb) (74 x bla) (hike x def) (hike x 123) (hike x 75) (hike x 129) (hike x deb) (hike x bla) (bleh x def) (bleh x 123) (bleh x 75) (bleh x 129) (bleh x deb) (bleh x bla)
  31. Total 36 entries
  32.  
  33. 6. The cardinality of the power set of the cross product of A and B
  34. |P(A x B)| =  68719476736
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement