[Solved] Convert String Extension to Linq [closed] October 28, 2022 by Kirat How about this: return (1 + s.Take(Pos).Count(c => c == '\n')); solved Convert String Extension to Linq [closed]