Have the function string challenge (str
I need answers in c with coderbyte ide that would be great thanks
ction stringChallenge (strArr) read strings stored in strArr, which will elements, the first will be a positive aber and the second element will be a er. Your goal is to determine how many binary number need to be changed to e decimal number correctly (either 0 or vice versa). For example: if strArr is 00"] then your program should return 1 ly 1 digit needs to change in the binary e first zero needs to become a 1) to present 56 in binary. 5624", "0010111111001"} **44","111111') 3 Resources a by Google rany help or documentation you might need
String Challenge Have the function StringChallenge (strArr) read the array of strings stored in strArr, which will contain two elements, the first will be a positive decimal number and the second element will be a binary number. Your goal is to determine how many digits in the binary number need to be changed to represent the decimal number correctly (either 0 change to 1 or vice versa). For example: if strArt is ["56","011000") then your program should return 1 because only 1 digit needs to change in the binary number the first zero needs to become a 1) to correctly represent 56 in binary. Examples Input: {"5624", "0010111111001"} Output: 2 Input: {"44", "111111"} Output: 3 Browse Resources powered by Google Search for any help or documentation you might need hlom For examnle: array indexing, Ruby
Have the function string challenge (str I need answers in c with coderbyte ide that would be great thanks
-
- Site Admin
- Posts: 899603
- Joined: Mon Aug 02, 2021 8:13 am