Source Code :
max([H],H).
max([H|T],R):-
max(T,M1),
H>=M1,
R is H,!.
max([H|T],R):-
max(T,M1),
H<M1,
R is M1.
Output :
In cs-assign blog you can find various types of computer program. Such as, programs in C, Java, Prolog etc.
Source code: //Write a program in C to convert a decimal number to binary using recursion. #include<stdio.h> long convertB_to_D(int d...
No comments:
Post a Comment