From d29e995d9a2445671251cd133c7f70b251dfd53b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Dami=C3=A1n=20Korpesio?= Date: Wed, 5 Jan 2022 12:46:14 +0100 Subject: [PATCH] prvy --- sk1a/main.c | 11 +++++------ sk1a/main.o | Bin 7472 -> 7496 bytes sk1a/maze.c | 10 +++++----- sk1a/maze.o | Bin 7064 -> 7064 bytes sk1a/program | Bin 21808 -> 21808 bytes 5 files changed, 10 insertions(+), 11 deletions(-) diff --git a/sk1a/main.c b/sk1a/main.c index ef56060..2072a82 100644 --- a/sk1a/main.c +++ b/sk1a/main.c @@ -15,12 +15,11 @@ void print_solution(char* matrix,int sz){ int main(){ char tmaze[SZ+1][SZ+1]={ - "*x ", - " xx ", - " x ", - " x ", - " ", - " ", + "*x ", + " xx ", + " x ", + " x ", + " ", }; char maze[SZ*SZ]; memset(maze,' ',SZ*SZ); diff --git a/sk1a/main.o b/sk1a/main.o index 60843e1abc1d62cc68e1d3c0aa0d98a96cb02c2f..bdb4139e3266442c8dca19db25a9c3fb7c6d5d0b 100644 GIT binary patch delta 529 zcmYjNJ4gdT5Z&4267M+U-`rh-uG&Ox>;#LfAcu)nY^<%sPS7S|VJ8V9cnlU6LKG1Z zi|By_2@lM{R}^LYDa9=ltfx|`Zf!JRjHw3(^9B}O1V4Y(X| zMRDD&wWu_f7h= size){d =1;} - if (maze[i + 1] == ' ' && l != 1) { + if (maze[i + 1] == ' ' /*&& i % size - 1 != 0 */&& l != 1) { maze[i + 1] = '*'; i++; p = 0; l = 0; h = 0; d = 0; - } else if (maze[i + size] == ' ' && h != 1) { + } else if (maze[i + size] == ' ' /*&& i < (size*size - size) != 0 */&& h != 1) { maze[i + size] = '*'; i = i + size; p = 0; l = 0; h = 0; d = 0; - } else if (maze[i - 1] == ' ' && p != 1) { + } else if (maze[i - 1] == ' ' /*&& i % size != 0 */&& p != 1) { maze[i - 1] = '*'; i--; p = 0; l = 0; h = 0; d = 0; - } else if (maze[i - size] == ' ' && d != 1) { + } else if (maze[i - size] == ' ' /*&& i >= size */&& d != 1) { maze[i - size] = '*'; i = i - size; p = 0; diff --git a/sk1a/maze.o b/sk1a/maze.o index 063ccdc2c24d4f8e6cc73ded6435c10a54fe066f..9dc2321b228971902a3e36291ffd96736a3adf66 100644 GIT binary patch delta 81 zcmbPXKEr&28z-aXWOq(EJ6{GS7Dg{tk#ttUHLNlvto*j=rKP2;61!Q2IrLat;d5a3&Gs2$!4hMZYE~T(>F=iQVMLkgxW5a}9G9FGm?0 z1A|8|@BhvJ1dg%PdmMLN0MZAfS3v0vP&qxPyll_fH<3=oNXY^4h0|pD%+y~w9)m#E=izK`xJnLN9XYueZT(yKR#JgtWaI> z_y7N$u5+4e=P;D=c=Xyja56Bwxcu|~e~_kqtWfpQlMjkXSnmW1pFGSj-vAV4_{=Z& z%Q4)i*S1@Yfx$7%v-6r`sAuO_#}LQPKcODIx-~%IU?0uD9?fq!UYy^|Cw_@zl0pjS zgKz);J1{aZ1We9VxGx(3WHGq%3A8ae^Rh9!GxD%=Ft`AP-T?88$(f4oj0ZMvRFvmo ztk`@}cOw(i0mjK2nZ!2FGH7B3%E+2rVPXuJ{K-t&M}n(^nSp_6qJvNo1EV5mDo{W3 z#GZO#Cov!k2tWcLAe70#D8&bnZmAdchDrxPWEq6A7#O8DCz>B&X0)8FW-Vvu%fQ6K z=*23M&MLTuRi=cM-!{Fpw3Jn1H>)s*9;*#RRxq7a@)IkcEi1n_NK$$?tHcCW;d!jq zo13ha7#SySUTR~<$jp=>wfTi@2=itu$2LZwhYmWqGcy)U=5*_4te8C0?K%^K_~at@ qG{%6SjU4a3+z7rvHQWEfXf3@bEW(8}R7N*~`l7HrFs$@p6Q* zF)(=a^4{P4Pv96!;&ImnS``WkX~$icC@36vU8Yb`0phFzan>j(C{zGB8$g^*KsHEb z8;G+5C8vC?|&-~a!2y3T2?ox@Pd z|3Mn|u|n0B{`>!b2awI+(e3*q#lx6KRRhQ=VSRBKsPg3D37`4p zemREw^xC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