input: Write a function to generate sample data for a web application using Python's faker library. The function should return a list of tuples containing name, email, and age. Each tuple represents a single user. If the input is an integer n, the function should generate n such tuples. If the input is not an integer or is less than or equal to 0, the function should return an empty list.
  assert generate_sample_data(3) == [('John Doe', 'john.doe@example.com', 25), ('Jane Smith', 'jane.smith@example.com', 30), ('Mike Johnson', 'mike.johnson@example.com', 50)]
  
  from faker import Faker
  
  def generate_sample_data(n):
   if not isinstance(n, int) or n <= 0:
   return []
   fake = Faker()
   return [(fake.name(), fake.email(), fake.random_int(min=18, max=60)) for _ in range(n)]
output: def generate_sample_data(n):
   if not isinstance(n, int) or n <= 0:
   return []
   fake = Faker()
   return [(fake.name(), fake.email(), fake.random_int(min=18, max=60)) for _ in range(n)]