subject

Atriangular number is a number that is the sum of the integers from 1 to some integer n. thus 1 is a triangular number because it's the sum of the integers from 1 to 1; 6 is a triangular number because it's 1+2+3=6. given the non-negative integer n, create a list of the first n triangular numbers. thus if n was 5, the list would be: [1, 3, 6, 10, 15]. associate the list with the variable triangulars.

2. an arithmetic progression is a sequence of numbers in which the distance (or difference) between any two successive numbers is the same. this in the sequence 1, 3, 5, 7, the distance is 2 while in the sequence 6, 12, 18, 24, the distance is 6. given the positive integer distance and the non-negative integer n, create a list consisting of the arithmetic progression between (and including) 1 and n with a distance of distance. for example, if distance is 2 and n is 8, the list would be [1, 3, 5, 7]. associate the list with the variable arith_prog.

3. given a variable temps that refers to a list, all of whose elements refer to values of type float, representing temperature data, compute the average temperature and assign it to a variable named avg_temp. besides temps and avg_temp, you may use two other variables -- kand total.

4. a list named parking_tickets has been defined to be the number of parking tickets given out by the city police each day since the beginning of the current year. (thus, the first element of the list contains the number of tickets given on january 1; the last element contains the number of tickets given today.) write some code that associates most_tickets with the largest value found in parking_tickets. you may, if you wish, use one additional variable, k. 5. associate the sum of the non-negative values in the list numbers with the variable sum.

ansver
Answers: 3

Another question on Computers and Technology

question
Computers and Technology, 22.06.2019 04:40
Amain idea is supported, explained, or expanded on with a numbers b. a concluding statement c. details d. a topic sentence. im e paragraphs reset nex next
Answers: 2
question
Computers and Technology, 22.06.2019 10:00
Businesses allocate resources for their best and most productive uses. the more a resource, the more costly it will be. a manufacturer that requires scarce and costly resources is likely to charge for its products.
Answers: 2
question
Computers and Technology, 22.06.2019 19:30
When creating a presentation in libre office impress, where does the editing of slides take place? a. the slides panel b. the center panel c. the tasks panel, under the masters pages tab d. the tasks panel, under the layouts tab
Answers: 1
question
Computers and Technology, 23.06.2019 00:00
Suppose you have 9 coins and one of them is heavier than others. other 8 coins weight equally. you are also given a balance. develop and algorithm to determine the heavy coin using only two measurements with the of the balance. clearly write your algorithm in the form of a pseudocode using the similar notation that we have used in the class to represent sorting algorithms
Answers: 1
You know the right answer?
Atriangular number is a number that is the sum of the integers from 1 to some integer n. thus 1 is a...
Questions
question
Health, 24.09.2021 01:00
question
Mathematics, 24.09.2021 01:00
question
Biology, 24.09.2021 01:00
question
Chemistry, 24.09.2021 01:00
Questions on the website: 13722367