Answer:
Explanation:
Since there are no line numbers in this question I will start counting from public class SelectionSort{ as line 1 and so on, as well as provide the code on that line.
The index of the smallest value is returned on line 8 where it says return min which shouldn't have any spaces and should be return minPosition;
The input array is given as an argument at the beginning of the function on line 2 where it says private static int positionMin (int] vals, int startPosition) {, as the variable vals.
This input array is also used as an argument on line 10 where it says Position; private static void swap(int] vals, int firstPosition, int secondPosition) and line 15 where it says vals[secondPosition] temp return public static void selSort(int| vals) {
Going over parts of a computer and how it functions will help you understand all the vital components that make up a computer.
Answer:
The python code is attached
Explanation:
- I defined a function called Fullname
- The function accepts 2 parameters first and last
- last[0] gives the first letter of the last variable
- last[0].upper() modifies the first letter as upper letter
- same applied to variable first
- + sign concatenates strings and variables to the variable name
- the function returns the variable name
Answer:
1. Hardware is the physical components that compose a system and provide physical quantity and quality to software applications and accomplish information processing tasks
2. Software is a program that carries out a set of instructions written in a programming language. It instructs a computer on how to carry out specific tasks. Programs can be saved permanently or temporarily.
3. Data may be mostly the raw resources used by information systems experts to give business intelligence to users. Traditional alphanumeric data, which is made up of numbers and alphabetical and other characters, is one type of data.
4. Networking is a resource of any computer system connected to other systems via a communications. It refers to the physical connections between all of the network's nodes. Communication networks are a critical resource component of all information systems, according to networking.
5. People are those who are directly or indirectly involved in the system. Direct users include developers, programmers, designers, and system administrators. Direct users can also be the stakeholder or end user who receives an output from the system. Indirect can be a manager who takes a brief check at the system to check that all criteria are satisfied.
6. Procedure is made up of stages or phases that result in an output. A method of continually receiving feedback on each part while analyzing the overall system by observing various inputs being processed or altered to create outputs.
Answer:
O(n²)
Explanation:
The worse case time complexity of insertion sort using binary search for positioning of data would be O(n²).
This is due to the fact that there are quite a number of series of swapping operations that are needed to handle each insertion.