This commit is contained in:
array-in-a-matrix 2023-01-19 12:42:52 -05:00
parent 198e16ad7f
commit f3e03e53b4
1 changed files with 3 additions and 1 deletions

View File

@ -1,5 +1,6 @@
import strutils, sequtils
#? validate if user input is of correct type
proc getInt: int =
while(true):
try:
@ -7,6 +8,7 @@ proc getInt: int =
except:
echo "Please enter an integer, try again."
#? validate if user input is of correct type
proc getFloat: float =
while(true):
try:
@ -81,7 +83,7 @@ proc dot* =
#? resultent matrix
var m: seq[seq[float]]
m = calcDot(m1, m2) #? calculate dot product (in procedures)
m = calcDot(m1, m2)
echo "\nFirst matrix is:"
printMatrix(m1)