Riešte problém, ktorý načíta 2 polia A a B zo súboru, porovná jednotlivé prvky poľa (i-ty prvok poľa A s i-tym prvkom poľa B), pričom ako výsledok porovnania vypíše počet zhodných čísiel na rovnakých pozíciách oboch polí, rovnako tak počet zhodne párnych a nepárnych čísiel na rovnakých pozíciách. Veľkosť polí nemusí byť rovnaká. Pri načítaní, je však orezaná dĺžkou menšieho poľa. Napr. A[3]={1,2,3}, B[4]={5,1,3,4}, budú sa teda vyhodnocovať tri prvky poľa, pričom počet rovnakých čísiel na rovnakých pozíciách je 1 (číslo 3), počet párnych čísiel na rovnakých pozíciách je 0, a počet nepárnych čísiel na rovnakých pozíciách je 2 (1. a 3. prvok).
Are you looking for informatika tutoring? Find the right informatika tutor for online or in-person tutoring near you.
We access the information stored on your device for this website to function properly. This includes, for example, cookies or local browser cache. We use this to store the data necessary for the functioning of the website, data used for analytical purposes, or data stored by third parties.
If this information is essential for the operation of this website, we store it automatically. For everything else, we need your consent, which you can choose to give below. Your consent is valid for 12 months. Should you refuse, we will ask you for consent again in 6 months, but you are free to change your mind at any time. For more information, please see our GDPR and Terms of Use.