Daily Tips: Data Science | SoloLearn: Learn to code for FREE!


Daily Tips: Data Science

Are there fellow students who have studied the Daily Tips: Data Science. The code coach challenge. For example: Missing Numbers. Coach / 105.

5/19/2020 4:16:49 PM

Aad Hoogenboom

8 Answers

New Answer


It is quite complex.


Thank you for your information. Good luck with the study.


first take the input from the user(in the form of a list) then sort it using the 'sort()' syntax then you can use the for loop and print all the values of i which are not in the list "According to me this is the simplest method". NO NEED OF DOING THINGS COMPLEX.



It took me 14 lines so probably didn't break any records but it was fun :-) N_input = int(input()) element_list = [] for n_in in range(N_input): element_list.append(int(input())) full_string = [] ind = min(element_list) while ind < max(element_list) + 1: full_string.append(ind) ind += 1 out_string = '' for element in full_string: if element not in element_list: out_string += str(element) + ' ' print(out_string[:-1])




Haven't done it yet, I'll give it a try