I just want to create my own simple function and I encountered an error that I can't fix. I'm using code blocks. The error is "expected primary-expression before 'int' that can be found in a void function. Can you give tips to prevent this error. Thank you and I will appreciate your help.
#include <iostream>
using namespace std;
int Time(int time)
{
  if(time>0 && time<12)
  cout<<"Good Morning";
  else if(time>=12 && time<17)
  cout<<"Good Afternoon";
  else if(time>=17 && time<=24)
  cout<<"Good Evening";
  else
  cout<<"Time is between (1-24)";
  return time;
}
void print_greet(string name)
{
  int myTime = Time(int time);//error in this line
  cout<<"Hello "<<name<<myTime<<endl;
}
 
    