+ 3
Can you write a program to detect a sequence in an array in C Lang.?
Program to detect a sequence in c, even if you know how to do it for strings, please share I think recursion in for loop having j variable make a move I'm trying to compare each value of sequence sub[] with arr[] and print something when the sequence is successfully traversed within the main array arr[] Can you help me how to proceed? My attempt: https://code.sololearn.com/cujqfQhgk9fG/?ref=app
7 ответов
+ 2
Sandeep Kushwaha
Thank you, Good Idea!
+ 1
We can *assist* you with your task. Can you show us your attempt?
+ 1
HonFu I'm stuck with the code here
code.sololearn.com/cujqfQhgk9fG/#c
I think recursion in for loop having j variable make a move
I'm trying to compare each value of sequence sub[] with arr[] and print something when the sequence is successfully traversed within the main array arr[]
Can you help me how to proceed?
+ 1
Sandeep Kushwaha Sharda patel can you help me with this
+ 1
Sandeep Kushwaha, I'm trying to detect a sequence if any in the string
Sub[] is sequence to be detected and
are[] is original input and comparing each element of sub[] with each element of are[] is my approach but I couldn't successfully justify the approach
Even if you know any other approach please share it😇