Course Solutions Uncategorized (Solved) : C Someone Please Explain Wrong Topthreetrend Function Help Would Greatly Appreciated Heres Q34414268 . . . .

(Solved) : C Someone Please Explain Wrong Topthreetrend Function Help Would Greatly Appreciated Heres Q34414268 . . . .

 

C++ : Can someone please explain what i am doing wrong here (inthe top_three_trend function)? Any help would be greatlyappreciated. Heres what I have below:

// Fills the provided vector with the 3 most-tweetedhashtags,

// in order from most-tweeted to least-tweeted.

//

// If there are fewer than 3 hashtags, then the vector isfilled

// with all hashtags (in most-tweeted to least-tweetedorder).

//

// Must run in O(n) time.

voidTrendtracker::top_three_trends(vector<string> &T){

// clear (max 3 each time)

T.clear();

// hold copy of original list

vector<Entry> copy;

copy = E;

  

// sort copy

int largest = 0; // index of largest atstart

while (largest < copy.size()){

  

for (int i = 0; i <copy.size(); i++){

if (copy[largest].pop < copy[i].pop){

// swap

OR

PayPal Gateway not configured

OR

PayPal Gateway not configured

Leave a Reply

Your email address will not be published. Required fields are marked *

Related Post

(Solved) : Help Understanding Java Please Explain Go Https Wwwhackerrankcom Challenges Staircase Prob Q26403341 . . . .(Solved) : Help Understanding Java Please Explain Go Https Wwwhackerrankcom Challenges Staircase Prob Q26403341 . . . .

<p>Help Understanding Java</p><p>Please explain how to go about this</p><p>https://www.hackerrank.com/challenges/staircase/problem</p> Expert Answer Answer to Help Understanding Java Please explain how to go about this https://www.hackerrank.com/challenges/staircase/problem...