[Solved] How to add parity bits on c# [closed]
This should do it: Console.WriteLine(“Please enter a 7- bit binary number”); string number = Console.ReadLine(); int count = 0; for(int i = 0; i < number.Length; i++) { if(number[i] == ‘1’) { count++; } } Console.WriteLine(“Your number with parity bit is “+ number + (count % 2).ToString()); I’d imagine this is beyond your current level, … Read more