Correction du min pour le 2.1 + ajout d'un breakpoint pour pouvoir inspecter les valeurs
This commit is contained in:
parent
193a745be1
commit
4c8d6c0708
2 changed files with 19 additions and 5 deletions
|
@ -157,20 +157,32 @@
|
|||
<Bp>
|
||||
<Number>0</Number>
|
||||
<Type>0</Type>
|
||||
<LineNumber>15</LineNumber>
|
||||
<LineNumber>14</LineNumber>
|
||||
<EnabledFlag>1</EnabledFlag>
|
||||
<Address>134218204</Address>
|
||||
<Address>134218164</Address>
|
||||
<ByteObject>0</ByteObject>
|
||||
<HtxType>0</HtxType>
|
||||
<ManyObjects>0</ManyObjects>
|
||||
<SizeOfObject>0</SizeOfObject>
|
||||
<BreakByAccess>0</BreakByAccess>
|
||||
<BreakIfRCount>1</BreakIfRCount>
|
||||
<Filename>.\Src\calcul_somme.s</Filename>
|
||||
<Filename>.\Src\principal.c</Filename>
|
||||
<ExecCommand></ExecCommand>
|
||||
<Expression>\\CHTI\Src/calcul_somme.s\15</Expression>
|
||||
<Expression>\\CHTI\Src/principal.c\14</Expression>
|
||||
</Bp>
|
||||
</Breakpoint>
|
||||
<WatchWindow1>
|
||||
<Ww>
|
||||
<count>0</count>
|
||||
<WinNumber>1</WinNumber>
|
||||
<ItemText>max,0x0A</ItemText>
|
||||
</Ww>
|
||||
<Ww>
|
||||
<count>1</count>
|
||||
<WinNumber>1</WinNumber>
|
||||
<ItemText>min,0x0A</ItemText>
|
||||
</Ww>
|
||||
</WatchWindow1>
|
||||
<MemoryWindow1>
|
||||
<Mm>
|
||||
<WinNumber>1</WinNumber>
|
||||
|
|
|
@ -2,7 +2,7 @@ int somme(int);
|
|||
|
||||
int main(void) {
|
||||
int max = 0;
|
||||
int min = 9999;
|
||||
int min = 999999;
|
||||
int resultat;
|
||||
for (int i = 0; i < 64; ++i) {
|
||||
resultat = somme(i);
|
||||
|
@ -11,6 +11,8 @@ int main(void) {
|
|||
else if (resultat < min)
|
||||
min = resultat;
|
||||
}
|
||||
int pause = 0;
|
||||
while(1){}
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue