Skip to main content
2 of 2
deleted 66 characters in body

Lua, 103 91 bytes

s,l=...s:gsub('.',load'c=...b=b or not s:find(c..c,1,1)and s:find(c,1,1)')print(b%l-1,b//l) 

Try it online!

Ungolfed version:

s,l=... --Take in haystack and line width as args s:gsub('.',function (d) --For each character in s b=b or not s:find(c..c,1,1)and s:find(c,1,1) --If there is only one instance of c, store location end) print(b%l-1,b//l) --Print results