input: Write a function named implement_iris_classification that implements a supervised learning algorithm for a classification task using the iris dataset. The function should load the dataset, preprocess the data, split it into training and test sets, train a KNeighborsClassifier, and evaluate its performance using a confusion matrix.
  assert implement_iris_classification('iris.csv')==print(confusion_matrix)
output: def implement_iris_classification(file_path):
      from sklearn.datasets import load_iris
      from sklearn.model_selection import train_test_split
      from sklearn.neighbors import KNeighborsClassifier
      from sklearn.metrics import confusion_matrix
      import pandas as pd
  
      # Load the dataset
      data = pd.read_csv(file_path)
      X = data.iloc[:, :-1]
      y = data.iloc[:, -1]
  
      # Split the dataset into training and test sets
      X_train, X_test, y_train, y_test = train_test_split(X, y, test_size=0.3, random_state=42)
  
      # Train a KNeighborsClassifier
      knn = KNeighborsClassifier(n_neighbors=3)
      knn.fit(X_train, y_train)
  
      # Evaluate the classifier using a confusion matrix
      y_pred = knn.predict(X_test)
      return confusion_matrix(y_test, y_pred)