diff --git a/easy/One_Hot_Encoding_of_Nominal_Values/One_Hot_Encoding_of_Nominal_Values.py b/easy/One_Hot_Encoding_of_Nominal_Values/One_Hot_Encoding_of_Nominal_Values.py index 1aa2fd8..d65c09a 100644 --- a/easy/One_Hot_Encoding_of_Nominal_Values/One_Hot_Encoding_of_Nominal_Values.py +++ b/easy/One_Hot_Encoding_of_Nominal_Values/One_Hot_Encoding_of_Nominal_Values.py @@ -1,5 +1,11 @@ import numpy as np + def to_categorical(x, n_col=None): - # Your code here - pass \ No newline at end of file + # Your code here + pass + + +x = np.array([0, 1, 2, 1, 0]) +output = to_categorical(x) +print(output)