Advertisement
Guest User

Untitled

a guest
Apr 27th, 2017
75
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Prolog 0.23 KB | None | 0 0
  1. add_matrices([], [], []).
  2. add_matrices([], _, false).
  3. add_matrices(_, [], false).
  4. add_matrices([Row1|T1], [Row2|T2], [V|L]) :- add_two_rows(Row1, Row2, V),
  5.                                              add_matrices(T1, T2, L).
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement