Create a python program that will accept positive or negative number and store it to a list. Accepting input will stop when empty input is encountered. Count and display all positive and negative number input and its index number in the list. Count and display all even and odd positive numbers and its index number. Exclude 0 input.
Example Output:
number 1: 78
number 2: 91
number 3: -5
number 4: 0
number 4: 8
number 5: -100
number 6: -2
number 7: 100
number 8:
There are 4 positive numbers
All positive numbers: 78 91 8 100
Positive numbers can be found at index number: 0 1 3 6
There are 3 negative numbers
All negative numbers: -5 -100 -2
Negative numbers can be found at index number: 2 4 5
There are 3 positive even numbers
Positive even numbers are: 78 8 100
Positive even numbers can be found at index: 0 3 6
There are 1 positive odd numbers
Positive odd numbers are: 91
Positive odd numbers can be found at index: 1
given an amount write a program in python to find a minimum number of currency notes of different denominations that sum to the given amount. Available note denominations are 1000, 500, 100, 50, 20, 5, 1.
The manager of the company has informed his assistant to enter the age of all the workers working in production department. Among all he has to find the employee with minimum age employee. Help the manager to find the minimum age employee by storing the all age of all employeesin 1D array. Use functions to solve this task.
write a program to implement reversal of a string using stack data structure in list of numbers
What is direct addressing? *
Fewer keys than array positions
Distinct array position for every possible key
Same array position for all keys
Fewer array positions than keys
What is a hash table? *
A structure that maps keys to values
A structure that maps values to keys
A structure used for storage
A structure used to implement stack and queue
Make a surprise list with the elements "Groucho," "Chico," and "Harpo."
Create a program that will accept positive or negative number and store it to a list. Accepting input will stop when empty input is encountered. Count and display all positive and negative number input and its index number in the list. Count and display all even and odd positive numbers and its index number. Exclude 0 input.
Example:
number 1: 78
number 2: 91
number 3: -5
number 4: 0
number 4: 8
number 5: -100
number 6: -2
number 7: 100
number 8:
There are 4 positive numbers
All positive numbers: 78 91 8 100
Positive numbers can be found at index number: 0 1 3 6
There are 3 negative numbers
All negative numbers: -5 -100 -2
Negative numbers can be found at index number: 2 4 5
There are 3 positive even numbers
Positive even numbers are: 78 8 100
Positive even numbers can be found at index: 0 3 6
There are 1 positive odd numbers
Positive odd numbers are: 91
Positive odd numbers can be found at index: 1
Create a program that will accept a string. Count the length of the string and convert all vowels to upper case and all consonants to lower case. Count number of vowels and consonants in the string. Display all vowels and consonant characters found in the string and the index number of each vowel and consonant character.
Example:
Enter a string: the quick brown fox
String length is 19
Converted string in upper case and lower case: thE qUIck brOwn fOx
There are 5 vowels
Vowel characters are: e u i o o
Vowel characters can be found at index: 2 5 6 12 17
There are 11 consonants characters.
Consonant characters are: t h q c k b r w n f x
Consonant characters can be found at index: 0 1 4 7 8 10 11 13 14 16 18
given two strings write a program to determine if a string s2 is a rotation of another string s1 in python in easy method