Questions
(Programming Language: Python) Complete the function remove number such that given a list of integers and...

(Programming Language: Python)

Complete the function remove number such that given a list of integers and an integer n, the function removes every instance of
n from the list. Remember that this function needs to modify the list, not return a new list.

# DO NOT ADD ANY OTHER IMPORTS from typing import List

def remove_number(lst: List[int], number: int) -> None:

"""

Remove every instance of number in lst. Do this *in-place*, i.e. *modify* the list. Do NOT return a new list.

>>> lst = [1, 2, 3]

>>> remove_number(lst, 3)

>>> lst

[1, 2]

"""

pass

In: Computer Science

Write an implementation of the ADT stack that uses a resizeable array to represent the stack...

Write an implementation of the ADT stack that uses a resizeable array to represent the stack items. Anytime the stack becomes full, double the size of the array. Maintain the stack's top entry at the beginning of the array.

Use c++ to write this code.

In: Computer Science

Build a Java class file to calculate the area of a figure (call it Area.java). The...

Build a Java class file to calculate the area of a figure (call it Area.java). The figure may be a circle or a square or a rectangle. The user will enter the type of figure they want through a Scanner. It they enter “C”, proceed to calculate the area of a Circle using values read in for radius. If they enter an “S”, then calculate the area of the circle using values read in for side. If they enter an “R”, then calculate using values read in for height and width. Use nested if statements for this lab.
Formulas are:
Circle: Area = 3.14*radius*radius
Square: Area= side*side
Rectangle: Area = Height*Width
3)Modify code for #2 to use the Switch Statements instead of “if” statements to make the decisions.


CIST 2371

In: Computer Science

Information Technology (IT) is an application of computers and telecommunications which stores, retrieves, transmits and manipulates...

Information Technology (IT) is an application of computers and telecommunications which stores, retrieves, transmits and manipulates data. It also encompasses other information technologies of a ubiquitous nature.

Describe using appropriate examples the ubiquitous nature of IT in the following cases. Clearly explain the input-output mechanism.

1. Wearable Computer

2. In the New Metro Express Project

In: Computer Science

Data must possess some key characteristics. Using example of a wearable computer, elaborate on the following:...

Data must possess some key characteristics. Using example of a wearable computer, elaborate on the following: RELIABLE, TIMELY, And COMPLETE

In: Computer Science

I'm trying to convert between different number representations in C++ , I have the prototype but...

I'm trying to convert between different number representations in C++ , I have the prototype but im not sure what do do from here

bool convertU(unsigned & n, const string & bits);

bits should have size exactly 5, and each char of bits should be '0' or '1'; otherwise

return false.

If bits is ok, set n to the number that bits represents as an unsigned and return true.

For example, convertU(n, "0101") and convertU(n, "10210") should return false;

convertU(n, "10011") should set n to 19 and return true.

In: Computer Science

In data normalization, the removal of partial dependencies is associated with the transition from ________. Select...

In data normalization, the removal of partial dependencies is associated with the transition from ________.

Select one:

a. Poorly structured data to first normal form (1NF)

b. First normal form (1NF) to second normal form (2NF)

c. Second normal form (2NF) to third normal form (3NF)

d. Third normal form (3NF) to Boyce-Codd normal form (BCNF)

Although the idea of a foreign key is useful for conceptual data modeling purposes, it is not actually possible to implement a foreign key in a real-world DBMS.

Select one:

a. True

b. False

Compared to the non-normalized design from which it was derived, a normalized database design will typically contain ________ inter-table relationships.

Select one:

a. More

b. Fewer

c. An equal number of

d. Zero

All of the following anomalies EXCEPT ________ can arise when using a list to store data.

Select one:

a. Deletion problems

b. Update problems

c. Query problems

d. Insertion problems

A referential integrity constraint can be used to verify that the values of a column in one table are valid in light of the values of a column in another table

Select one:

a. True

b. False

In: Computer Science

2 Write a Java program called Pattern that prints an 8-by-8 checker box pattern using an...

2 Write a Java program called Pattern that prints an 8-by-8 checker box pattern using an if loop.

In: Computer Science

Write a Java program called Decision that includes a while loop to prompt the user to...

Write a Java program called Decision that includes a while loop to prompt the user to enter 5 marks using the JOptionPane statement and a System. Out statement to output a message inside the loop highlighting a pass mark >= 50 and <= 100. Any other mark will output a messaging stating it’s a fail.

In: Computer Science

PLEASE USE PYTHON CODE 7. determine the two roots of sinx+3cosx-2 =0 that lie in the...

PLEASE USE PYTHON CODE

7. determine the two roots of sinx+3cosx-2 =0 that lie in the interval (-2,2). use the Newton- Raphson method and solve by the secant formula

In: Computer Science

Translate the following C program to Pep/9 assembly language: #include <stdio.h> char toLower(char ch) { if...

Translate the following C program to Pep/9 assembly language:

#include <stdio.h>

char toLower(char ch)
{
if (ch >= 'A' && ch <= 'Z' )
       ch += 'a' - 'A';
return ch;
}

int main()
{
char ch, conversion;
printf("Enter an uppercase letter: ");
scanf("%c", &ch);
conversion = toLower(ch);
printf("\nLetter after conversion: %c\n\n", conversion);
return 0;
}

In: Computer Science

4   Write an algorithm to settle the following questions: Accept a starting balance (For example :A...

4   Write an algorithm to settle the following questions:

Accept a starting balance (For example :A bank account starts out with $10,000) Accept an Interest rate (For example: 6 percent per year is 0.005 percent per month).

Accept an amount to withdraw every month (For example: Every month, $500 is withdrawn to meet college expenses.)

After how many years is the account depleted? (You are to loop and find out how many months this will take) (For example: Suppose the values ($10,000, 6 percent, $500) were user selectable, then how many months would it take to deplete the account?)

Are there values for which the algorithm you developed would not terminate? (For example if the interest calculated for each month exceeds the withdrawal every month). If so, change the algorithm to make sure it always terminates.

Don't write the program, just write it in pseudo English.

In: Computer Science

Software Testing Question Program P2 CFG. a) Identify the basic blocks for the following program P2...

Software Testing Question

Program P2 CFG.

a) Identify the basic blocks for the following program P2 written in pseudo-code.

b) Draw the control flow graph.

Program P2

1) integer A, B;

2) input (A);

3) B = 1;

4) while (int i=1; i<=A; i++)

5) {

6) B = B * i;

7) if (B>13)

8) B = B / 2;

9) else 1

0) B = B * 2;

11) }

12) output (A,B);

13) end;

In: Computer Science

String Input Console Application and Program Analysis Demonstrate an understanding of basic C++ programming concepts by...

String Input Console Application and Program Analysis

Demonstrate an understanding of basic C++ programming concepts by completing the following:

  • Program: Create a simple C++ console application that will write a program that will take string input from a user. Your program should reverse the string and then print the output to the screen. Take input from the user 3 times for varying string lengths.
  • Program Analysis: Given your program implementation, discuss and identify the possible vulnerabilities that may exist. If present, discuss solutions to minimize the vulnerabilities. Then discuss and identify possible problems that can result in errors for string manipulation of data. Your program analysis should be 1-2 pages in length.

In: Computer Science

Please, write code in c++. Using iostream and cstring library Use pointers! You given a text.Your...

Please, write code in c++. Using iostream and cstring library

Use pointers!

You given a text.Your task is to write a function that will find the longest sequence of digits inside.
Note that the output have to be presened just like in sample.

Note. The program have to use pointer.

Input:
First line contains one line that is not longer than 1000.

Output:
The longest sequence of numbers.All numbers are positive and integers.

Samples:

INPUT OUTPUT
1 This is the longest - 10001 number 10 001
2 101 fdvnjfkv njfkvn fjkvn jffdvfdvfd2010 2 010
2 1a11 11

In: Computer Science