User
Pass
2FA
 
 

Problema Informatica

 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Freakz Forum Index -> Trash Bin -> Trash -> Homework zone
Author Message1153
Vlad_Taekwondo WTF

[Satanistu']



Status: Offline
(since 06-01-2018 16:34)
Joined: 29 Aug 2013
Posts: 1706, Topics: 53
Location: War3.Freakz.Ro

Reputation: 254.5
Votes: 15

 
Post Posted: 15-01-2016, 08:30:19 | Translate post to: ... (Click for more languages)

Dintr-un sir de N numere aflate in ordine crescatoare sa se afle cate sunt distincte.

Presupun ca este o problema de clasa a VII-a. Din pacate, eu nu am facut orele de Informatica pana in clasa a IX-a deoarece nu aveam profesor.




Y!M: vlad_tkd
0 0
  
Back to top
View user's profile Send private message Yahoo! Messenger ID
PsychoLove

[Silence In The Snow]



Status: Offline
(since 05-01-2024 17:19)
Joined: 12 Aug 2013
Posts: 5177, Topics: 299
Location: Behind you.

Reputation: 1306.4
Votes: 480

      Battletag: postrow.ID_BATTLE_NET} 
Post Posted: 18-01-2016, 18:27:29 | Translate post to: ... (Click for more languages)

#include <iostream>
using namespace std;

int main()
{ int n, nr=0, v[100];
cout<<"n="; cin>>n;
for(int i=0;i<n;i++)
cin>>v[i];

for(int i=0;i<n-1;i++)
if (v[i] != v[i+1])
nr++;
cout>>nr;

return 0; }

Nu am testat-o, dar ar trebui sã meargã. Testeazã și dacã nu e ok sau e ceva ce nu înțelegi îmi dai pm.
@Vlad_Taekwondo WTF





Dreams.. That's all we have.

0 0
  
Back to top
View user's profile Send private message

  Topic locked


Topic is closed, you cannot post any messages in it anymore

Locked by PsychoLove, 18 January 2016 16:27



 
This forum is locked: you cannot post, reply to, or edit topics.   This topic is locked: you cannot edit posts or make replies.    Freakz Forum Index -> Trash Bin -> Trash -> Homework zone  


The time now is 29-11-2024, 06:29:57
Copyright info

Based on phpBB ro/com
B

 
 
 







I forgot my password


This message appears only once, so
like us now until it's too late ! :D
x