float getExpRndmNumber(int max){ //Implementation of the function. //Use a hit or miss aproach as in the previous excercise. return 1; } int ex12_frwl(){ TH1F* h1 = new TH1F("h1", "Exponentialverteilung", 100, 0, 10); const int iterations = 10000; for (int ii = 0; ii < iterations; ii++){ h1->Fill(getExpRndmNumber(10)); } h1->Draw(); TF1* myExp = new TF1("myExp", "[0]*TMath::Exp(-x)", 0,10); //Parameter 0 needs to be set to a different value. //How do you calculate the right parameter value? myExp->SetParameter(0, 5); myExp->Draw("same"); }