#include <stdio.h>
#include <string.h>

int main() {
    // char str1[10];
    // char str2[10];
    // scanf("%s", str1);
    // scanf("%s", str2);
    // for(int i=0;i<strlen(str1);i++){
    //     printf("%c", str1[i]);
    // }
    // printf("&");
    //  for(int i=0;i<strlen(str2);i++){
    //     printf("%c", str2[i]);
    // }
    
    int i=0;
    int cnt=0; 
    while(1){
        int num;
        scanf("%d", &num);
        if (num == 7){
            cnt = i;
            break;
        }
        i++;
    }
    printf("%d", cnt);
}

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: