🔒 Closed Help! C++

Status
Not open for further replies.

Mel143r

Fanatic
Hi guys baka meron ditong marunong gumawa ng pseudocode. Baliktad kasi ko marunong ako gumawa ng code pero pseudocode hindi hihi pede po pahelp?
eto po yung code ko.

#include <iostream>
using namespace std;

int main()
{
//Initialize array
int arr[] = {0, 1, 2, 3, 4, 5, 1, 4, 8, 9, 2};

//Calculate length of array arr
int length = sizeof(arr)/sizeof(arr[0]);
cout <<"Array : ";

//Searches for duplicate element
for(int i = 0; i < length; i++) {
for(int j = i + 1; j < length; j++) {
if(arr == arr[j])
cout <<" " <<arr[j];
}
}
return 0;
}
 
Status
Not open for further replies.

About this Thread

  • 1
    Replies
  • 280
    Views
  • 2
    Participants
Last reply from:
Arcturus

Trending Topics

Online now

Members online
1,025
Guests online
1,434
Total visitors
2,459

Forum statistics

Threads
2,290,640
Posts
29,065,686
Members
1,211,457
Latest member
singkamaskamatis
Back
Top