summaryrefslogtreecommitdiff
path: root/1553/CH5/EX5.22/5Ex22.sce
blob: 67d6442184e33ca6927e4011446c97faf3665f80 (plain)
1
2
3
4
5
6
7
8
9
10
//chapter 5 Ex 22
clc;
clear;
close;

//let the value to be found out be z
x=(sqrt(5)+sqrt(3))/(sqrt(5)-sqrt(3));
y=(sqrt(5)-sqrt(3))/(sqrt(5)+sqrt(3))
z=x^2+y^2;
mprintf("The value of expression (x^2+y^2)is %.0f",z);