Kth Node from the End

hey please look at my code why i am not able to pass test case 3 what is wrong in this ??

void kelement(Node *&head, int k){
    Node *temp = head;
    Node *fast=head;
    Node *slow =head;
    for(int i=1;i<=k;i++){
        fast =fast->next;
    }
    while(fast !=NULL){
        
        fast=fast->next;
        slow=slow->next;
    }
    // slow=slow->next;
    cout<<slow->data;
}

sorry i did not get the &lt &gt and why have you taken this amp

image