Table of Contents

naslov1

zatrecizad
 
mat1=load('ulaz1.txt');
mat2=load('ulaz2.txt');
mat3=load('ulaz3.txt');
 
arsred=(mat1+mat2+mat3)/3;
domen=numel(mat1);
 
od1=abs(mat1-arsred);
od2=abs(mat2-arsred);
od3=abs(mat3-arsred);
br(1)=0;
br(2)=0;
br(3)=0;
 
for i=1:1:domen,
	z=[od1 od2 od3];
	maximum=max(z);
	if od1(i)==maximum
		br(1)++;
	elseif od2(i)==maximum
		br(2)++;
	elseif od3(i)==maximum
		br(3)++;
	end
end
m=max(br);
if m==br(1)
	printf("Ulaz1.txt\n");
elseif m==br(2)
	printf("Ulaz2.txt\n");
elseif m==br(3)
	printf("Ulaz3.txt\n");
end

naslov2

x2

naslov3

Nikola Andric 51/101)

1 2
4
122
1) indeks
 
studentske-strane-nikola.andric-octave.txt · Last modified: 2012/02/07 22:47 by milos.damljanovic
 
Except where otherwise noted, content on this wiki is licensed under the following license:CC Attribution-Noncommercial-Share Alike 3.0 Unported
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki