is is used uninitialized in this function :     I have completed the program, but I'm getting one error. it says total,min,hours,sec is used uninitialized in this function. I tried using different variables, and I initialized the variable   but it  still didn't work. Can someone help me figure out what did I do wrong. I put time( total,  hours,   mins,  secs);  

    
    my program - #include <iostream>
    using namespace std; 
     void time(int, int, int, int); 
    
     int main() 
     { 
     int total; 
     int hours;
     int mins;
     int seconds;
     int secs; 
    
     cout << "Enter the number of seconds: "; 
     cin >> seconds; 
      time( total,  hours,   mins,  secs); 
     cout << "The number of hours is: " << hours << endl; 
     cout << "The number of minutes is: " << mins << endl; 
     cout << "The number of seconds is: " << secs << endl; 
     return 0; 
     } 
    void time(int total, int &hours, int &min, int &sec) 
    { 
        int rem1; 
        hours = total / 3600; 
        rem1 = total % 3600; 
        min = rem1 / 60; 
        sec = rem1 % 60; 
        return ; 
    } 
      output -     15:38: warning: 'total' is used uninitialized in this function [-Wuninitialized]
    15:38: warning: 'hours' is used uninitialized in this function [-Wuninitialized]
    15:38: warning: 'mins' is used uninitialized in this function [-Wuninitialized]
    15:38: warning: 'secs' is used uninitialized in this function [-Wuninitialized]
   



I have completed the program, but I'm getting one error. it says total,min,hours,sec is used uninitialized in this function. I tried using different variables, and I initialized the variable   but it  still didn't work. Can someone help me figure out what did I do wrong. I put time( total,  hours,   mins,  secs);
    
     

