|Just off the top of my head, I write in vb, not that quick in c sharp. But I put about 10 minutes into it just to test 1 char. I would have to come back to convert the program to test char positions 2-4-6-7. I'm a little fuzzy on integer array, in which I can loop the Integer array of p1 to test 2-4-6-7 in the same loop, and produce a exit code such as 0 for success or 1 for failure.
If I used the integer array of p1 for looping, I could just match the int value to the char position much faster. But that's my weakness.
Dim p1() as Integer = 2467
Anyways this is just a starter thought
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
Dim uPassword() As Char = "fortune"
Dim p1 As Integer = 2
Dim p1c As Char = "r"
Dim pMatch As Integer = 1
Dim input(uPassword.Length - 1) As Char
For i As Integer = 0 To uPassword.Length - 1
input(i) = uPassword(i)
If (p1 = i) Then
If (uPassword(i) = p1c) Then
pMatch = 0
Response.Write("<span style=""color: black;"">" & input & "</span>" & _
<span style=""color: black;"">" & pMatch.ToString & "</span>")