summaryrefslogtreecommitdiff
path: root/1553/CH8/EX8.2
diff options
context:
space:
mode:
Diffstat (limited to '1553/CH8/EX8.2')
-rw-r--r--1553/CH8/EX8.2/8Ex2.sce13
1 files changed, 13 insertions, 0 deletions
diff --git a/1553/CH8/EX8.2/8Ex2.sce b/1553/CH8/EX8.2/8Ex2.sce
new file mode 100644
index 000000000..846121861
--- /dev/null
+++ b/1553/CH8/EX8.2/8Ex2.sce
@@ -0,0 +1,13 @@
+//chapter 8 Ex 1
+
+clc;
+clear;
+close;
+//let age of younger person be x
+//by the given condition: equation is 3(x-6)=x+16-6;
+mycoeff=[-28 2];
+p=poly(mycoeff,"x","coeff");
+x=roots(p);
+mprintf("Their present ages are %d years and %d years",x,x+16);
+
+