Question: 
Write a function to check if all the elements in tuple have same data type or not.


Model's Code:
def check_type(t):
    return all(isinstance(x, type(t[0])) for x in t)



Sample Correct Code:
def check_type(test_tuple):
  res = True
  for ele in test_tuple:
    if not isinstance(ele, type(test_tuple[0])):
      res = False
      break
  return (res) 


Asserts:
assert check_type((5, 6, 7, 3, 5, 6) ) == True
assert check_type((1, 2, "4") ) == False
assert check_type((3, 2, 1, 4, 5) ) == True


Tests:
Test 1 of 3: PASS
Test 2 of 3: PASS
Test 3 of 3: PASS

Test 222 of 974: 162/222 (72.97297297297297%): success