#Write a function called fancy_find. fancy_find should have #two parameters: search_within and search_for. # #fancy_find should check if search_for is found within the #string search_within. If it is, it should print the message #"[search_for] found at index [index]!", with [search_for] #and [index] replaced by the value of search_for and the #index at which it is found. If search_for is not found #within search_within, it should print, "[search_for] was #not found within [search_within]!", again with the values #of search_for and search_within. # #For example: # # fancy_find("ABCDEF", "DEF") -> "DEF found at index 3!" # fancy_find("ABCDEF", "GHI") -> "GHI was not found within ABCDEF!"

Answers

Answer 1

Answer:

Here is the Python program:

def fancy_find(search_within , search_for):  # function definition of fancy_find function that takes two parameters

   index = 0  #to store the index of search_within where the search_for string is found

   if search_for in search_within:  #checks if the string search_for is present in string search_within

       sf = search_for[0]  #points to the first character of the search_for

       for sw in search_within:  #iterates through search_within

           if sw == sf:  #if the first character of search_for is equal to the character at sw index of search_within

               if search_within[index:index+len(search_for)] == search_for:  #checks if the value of search_for is found in search_within

                   print(search_for,"found at index",index,"!")  #if above condition is true prints the message "[search_for] found at index [index]!", with [search_for] and [index] replaced by the value of search_for and the index at which it is found

                   return ""  

           index += 1  #increments value of index at each iteration

   print(search_for,"is not found within", search_within)  #if search_for is not found within search_within, prints message "[search_for] was not found within [search_within]!" with the values of search_for and search_within.

   return ""    

#following two statements are used to test the working of above function

print(fancy_find("ABCDEF", "DEF"))  #calls fancy_find() passing "ABCDEF" as search_within and "DEF" as search_for

print(fancy_find("ABCDEF", "GHI")) #calls fancy_find() passing "ABCDEF" as search_within and "GHI" as search_for

Explanation:

The program is well explained in the comments. I will explain the working of the function with the help of an example:

Suppose

search_within = "ABCDEF"

search_for = "DEF"

We have to find if search_for i.e. DEF is present in search_within i.e. ABCDEF

if search_for in search_within statement checks using in operator that if DEF is included in ABCDEF. Here this condition evaluates to true so the next statement sf = search_for[0]  executes which sets the first element of search_for i.e. D to sf. So sf = 'D'

for sw in search_within this statement has a for loop that iterates through ABCDEF and works as following:

At first iteration:

sw contains the first character of search_within  i.e. A

if sw == sf: condition checks if the first character of the search_for i.e. D is equal to sw i.e. A. Its not true so the program control moves to this statement:

index += 1 This increases the value of index by 1. index was initialized to 0 so now it becomes 1. Hence index=1

At second iteration:

sw contains the second character of search_within  i.e. B

if sw == sf: condition checks if the first character of the search_for i.e. D is equal to sw i.e. B Its not true so the program control moves to this statement:

index += 1 This increases the value of index by 1. index was initialized to 0 so now it becomes  2. Hence index=2

At third iteration:

sw contains the third character of search_within  i.e. C

if sw == sf: condition checks if the first character of the search_for i.e. D is equal to sw i.e. C Its not true so the program control moves to this statement:

index += 1 This increases the value of index by 1. index was initialized to 0 so now it becomes  3. Hence index=3

At fourth iteration:

sw contains the third character of search_within  i.e. D

if sw == sf: condition checks if the first character of the search_for i.e. D is equal to sw i.e. D. Its true so so the program control moves to this statement:

  if search_within[index:index+len(search_for)] == search_for:

current value of index=3

len(search_for) returns the length of DEF i.e. 3

So the if condition checks for the search_for in search_within. The statement becomes:

if search_within[3:3+3] == search_for:

search_within[3:3+3]  means from 3rd index position of search_within to 6-th index position of the search_within. This means from 4th element of search_within i.e. D to the last. Hence search_within[3:3+3] is equal to DEF.

search_for = DEF so

if search_within[3:3+3] == search_for: checks if

search_within[3:3+3] = DEF is equals to search_for = DEF

Yes it is true so

print(search_for,"found at index",index,"!") statement is executef which prints the following message:

DEF found at index 3!

This output is because search_for = "DEF" and index=3

#Write A Function Called Fancy_find. Fancy_find Should Have #two Parameters: Search_within And Search_for.

Related Questions

Write a for loop to print all NUM_VALS elements of array hourlyTemp. Separate elements with a comma and space. Ex: If hourlyTemp = {90, 92, 94, 95}, print:
90, 92, 94, 95
Note that the last element is not followed by a comma, space, or newline.
#include
using namespace std;
int main() {
const int NUM_VALS = 4;
int hourlyTemp[NUM_VALS];
int i = 0;
hourlyTemp[0] = 90;
hourlyTemp[1] = 92;
hourlyTemp[2] = 94;
hourlyTemp[3] = 95;
/* Your solution goes here */
cout << endl;
return 0;
}

Answers

Answer:

string sep = "";

for (i = 0; i < NUM_VALS; i++) {

 cout << sep << hourlyTemp[i];

 sep = ", ";

}

Explanation:

Insert the snippet at the commented location.

With the absence of a join() method as found in other languages, it is always a hassle to suppress that separator comma from appearing at the beginning or the end of your output. This solution is nice since it doesn't require any magic flags to keep track of wether the first element was printed.

If you implement too many security controls, what portion of the CIA triad (Information Assurance Pyramid) may suffer?
a. Availability
b. Confidentiality
c. Integrity
d. All of the above

Answers

Answer:

Option A

Availability

Explanation:

The implementation of too many security protocols will lead to a reduction of the ease at which a piece of information is accessible.  Accessing the piece of information will become hard even for legitimate users.

The security protocols used should not be few, however, they should be just adequate to maintain the necessary level of confidentiality and integrity that the piece of information should have, While ensuring that the legitimate users can still access it without much difficulty.

A user in an apartment building on a wireless network is no longer able to print to the network printer. The user has been able to print to the printer in the past and nothing on the network has changed. A technician notices that the user has a different IP address scheme than what was originally setup and is able to browse the Internet using that IP address scheme. What should he do?

Answers

Answer:

The technician should either provide a route from the user's IP scheme to the printer or change the user's IP scheme to be within the same scheme as the printer.

Explanation:

The most likely reason the user is unable to print to the printer is that the user's computer cannot path the current address to the address of the printer.  Without the printer being on the same subnet as the user's computer, the computer has no way of being able to tell where the printer is.

The two solutions to this are to either add a route to the user's computer explicitly telling the user's computer where to trace to find the printer or to change the user's computer to match the IP scheme of the printer.

Cheers.

Give five types of hardware resource and five types of data or software resource that can usefully be shared. Give examples of their sharing as it occurs in practice in distributed systems.

Answers

Answer:

Answered below

Explanation:

Hardware resources that can be usefully shared and also examples of their sharing include;

A) CPU servers, which carry out computations for clients.

B) Network capacity transmission of data or packet transmission is done using the same circuit, meaning many communication channels share the same circuit.

C) Screen networks windows systems which enable processes in remote computers to update the contents of their local server.

D) Memory cache server.

E) Disk file server, virtual disk server.

Softwares include;

A) Web-page web servers which allow client programs to have read-only access to page contents.

B) Database whose contents can be usefully shared.

C) File servers enable multiple users access to files .

D) Objects can be shared in distributed systems example shared ticket booking, whiteboard etc.

E) Exclusive lock which enables the coordination of accessing a special resource.

Briefly describe the importance of thoroughly testing a macro before deployment. What precautions might you take to ensure consistency across platforms for end users?

Answers

Answer:

Answered below

Explanation:

A macro or macroinstruction is a programmable pattern which translates a sequence of inputs into output. It is a rule that specifies how a certain input sequence is mapped to a replacement output sequence. Macros makes tasks less repetitive by representing complicated keystrokes, mouse clicks and commands.

By thoroughly testing a macro before deployment, you are able to observe the flow of the macro and also see the result of each action that occurs. This helps to isolate any action that causes an error or produces unwanted results and enable it to be consistent across end user platforms.

After a new firewall is installed, users report that they do not have connectivity to the Internet. The output of the ipconfig command shows an IP address of 169.254.0.101. Which of the following ports would need to be opened on the firewall to allow the users to obtain an IP address? (Select TWO).
A. UDP 53
B. UDP 67
C. UDP 68
D. TCP 53
E. TCP 67
F. TCP 68

Answers

Answer:

B. UDP 67

C. UDP 68

Explanation:

In this scenario, after a new firewall is installed, users report that they do not have connectivity to the Internet. The output of the ipconfig command shows an IP address of 169.254.0.101. The ports that would need to be opened on the firewall to allow the users to obtain an IP address are both the UDP 67 and UDP 68. UDP is an acronym for user datagram protocol in computer networking and it is part of the transmission control protocol/internet protocol (TCP/IP) suite.

Generally, the standard Internet communications protocols which allow digital computers to transfer (prepare and forward) data over long distances is the TCP/IP suite.

Also, the UDP 67 and 68 ports is responsible for the connectionless framework which is typically being used by the dynamic host configuration protocol (DHCP) that is used to assign IP addresses to various computer users and manage their leases.

UDP 67 is the destination port for a DHCP server while the UDP 68 is the port number for the computer user (client).

Hence, for the users to have access to the internet or internet connectivity both UDP 67 and 68 must be opened on the firewall.

Develop a simple game that teaches kindergartners how to add single-digit numbers. Your function game() will take an integer n as input and then ask n single-digit addition questions. The numbers to be added should be chosen randomly from the range [0, 9] (i.e.,0 to 9 inclusive). The user will enter the answer when prompted. Your function should print 'Correct' for correct answers and 'Incorrect' for incorrect answers. After n questions, your function should print the number of correct answers.

Answers

Answer:

2 correct answer out of 3

What is the output of the following Python program? try: fin = open('answer.txt') fin.write('Yes') except: print('No') print('Maybe')

Answers

(<ANSWER RETRACTED>)

Explain how/where could you change the NIC Card configuration from dynamic DHCP setting to an IP address of 10.254.1.42 with a subnet mask of 255.255.0.0 and a gateway of 10.254.0.1. (hint: we spoke about 2 different methods)

Answers

Answer:

Using the terminal in linux OS to configure a static ip address, gateway and subnet mask.

Explanation:

-Enter the terminal in the linux environment and use the ifconfig eth0 or -a to bring up the main network interface and other network interfaces.

- for static network configuration, use;

  - ifconfig eth0 10.254.1.42  

  - ifconfig eth0 netmask 255.255.0.0

  - ifconfig eth0 broadcast 10.254.255.255

- and add a default gateway with;

 -  route add default gw 10.254.0.1  eth0.

- Now verify the settings with the ifconfig eth0 command.

Suppose that a class named ClassA contains a private nonstatic integer named b, a public nonstatic integer named c, and a public static integer named d. Which of the following are legal statements in a class named ClassB that has instantiated an object as ClassA obA =new ClassA();?

a. obA.b 12;
b. obA.c 5;
c. obA.d 23;
d. ClassA.b=23;
e. ClassA.c= 33;
f. ClassA.d= 99;

Answers

Answer:

b. obA.c 5;

d. ClassA.b=23;

f. ClassA.d = 99;

Explanation:

Java is a programming language for object oriented programs. It is high level programming language developed by Sun Microsystems. Java is used to create applications that can run on single computer. Static variable act as global variable in Java and can be shared among all objects. The non static variable is specific to instance object in which it is created.

As an ICT student teacher using convincing and cogent reasons explain why you think operating system is pivotal in teaching and learning

Answers

Answer:

An operating system (OS) is a software which is responsible for the management of computer hardware, software, and also provides common services for computer programs.

Operating System is pivotal in teaching and learning because:

1. It enables computer programs to run smoothly on various computer devices.

2. The Operating System gives teachers the opportunity to install learning apps on their devices for ease of teaching.

3. It enables students to download and install learning applications, download and upload assignments, etc.

4. The Operating System makes video conferencing for online tuition easy and smooth.

5. It makes computer users to interact with other applications and softwares within a device.

Operating systems are found on many computer devices e.g: mobile phones, video games, PCs, supercomputers, etc.

Operations that a given computing agent can perform are called

Answers

Answer:

Primitive operation

Explanation:

Operations that a given computing agent can perform are called primitive operations.

These operations are basic arithmetic work done by an algorithm such as assigning a variable, calling a method, returning an array, etc. They are sometimes written in pseudo-code.

If the data rate is 10 Mbps and the token is 64 bytes long (the 10-Mbps Ethernet minimum packet size), what is the average wait to receive the token on an idle network with 40 stations? (The average number of stations the token must pass through is 40/2 = 20.) Ignore the propagation delay and the gap Ethernet requires between packets.

Answers

Answer:

1.024x10^-5

Explanation:

To calculate the transmission delay bytes for the token,

we have the token to be = 64bytes and 10mbps rate.

The transmission delay = 64bytes/10mbps

= 51.2 microseconds

A microsecond is a millionth of a second.

= 5.12 x 10^-5

The question says the average number of stations that the token will pass through is 20. Remember this value is gotten from 40/2

20 x 5.12 x 10^-5

= 0.001024

= 1.024x10^-5

Therefore on an idle network with 40 stations, the average wait is

= 1.024x10^-5

#Below is a class representing a person. You'll see the
#Person class has three instance variables: name, age,
#and GTID. The constructor currently sets these values
#via a calls to the setters.
#
#Create a new function called same_person. same_person
#should take two instances of Person as arguments, and
#returns True if they are the same Person, False otherwise.
#Two instances of Person are considered to be the same if
#and only if they have the same GTID. It does not matter
#if their names or ages differ as long as they have the
#same GTID.
#
#You should not need to modify the Person class.

class Person:
def __init__(self, name, age, GTID):
self.set_name(name)
self.set_age(age)
self.set_GTID(GTID)

def set_name(self, name):
self.name = name

def set_age(self, age):
self.age = age

def set_GTID(self, GTID):
self.GTID = GTID

def get_name(self):
return self.name

def get_age(self):
return self.age

def get_GTID(self):
return self.GTID

#Add your code below!

#Below are some lines of code that will test your function.
#You can change the value of the variable(s) to test your
#function with different inputs.
#
#If your function works correctly, this will originally
#print: True, then False.
person1 = Person("David Joyner", 30, 901234567)
person2 = Person("D. Joyner", 29, 901234567)
person3 = Person("David Joyner", 30, 903987654)
print(same_person(person1, person2))
print(same_person(person1, person3))

Answers

Answer:

Here is the function same_person that takes two instances of Person as arguments i.e. p1 and p2 and returns True if they are the same Person, False otherwise.

def same_person(p1, p2):  #definition of function same_person that takes two parameters p1 and p2

   if p1.GTID==p2.GTID:  # if the two instances of Person have same GTID

       return True  #returns true if above condition evaluates to true

   else:  #if the two instances of Person do not have same GTID

       return False #returns false when two persons have different GTID

Explanation:

person1 = Person("David Joyner", 30, 901234567)  #first instance of Person

person2 = Person("D. Joyner", 29, 901234567)  #second instance of Person

person3 = Person("David Joyner", 30, 903987654)  #third instance of Person

print(same_person(person1, person2))  #calls same_person method by passing person1 and person2 instance of Person to check if they are same

print(same_person(person1, person3)) #calls same_person method by passing person1 and person3 instance of Person to check if they are same

The function works as follows:

For function call print(same_person(person1, person2))

The GTID of person1 is 901234567 and that of person2 is 901234567

If condition if p1.GTID==p2.GTID in the function same_person checks if the GTID of person1 is equal to the GTID of person2. This condition evaluates to true because GTID of person1 = 901234567 and GTID of person2 = 901234567

So the output is:

True

For function call print(same_person(person1, person3))

The GTID of person1 is 901234567 and that of person3 is 903987654

If condition if p1.GTID==p2.GTID in the function same_person checks if the GTID of person1 is equal to the GTID of person3. This condition evaluates to false because GTID of person1 = 901234567 and GTID of person2 = 903987654 and they are not equal

So the output is:

False

The complete program along with its output is attached in a screenshot.

Where can you find detailed information about your registration, classes, finances, and other personal details? This is also the portal where you can check your class schedule, pay your bill, view available courses, check your final grades, easily order books, etc. A. UC ONE Self-Service Center B. Webmail C. UC Box Account D. ILearn

Answers

Answer:

A. UC ONE Self-Service Center

Explanation:

The UC ONE Self-Service Center is an online platform where one can get detailed information about registration, classes, finances, and other personal details. This is also the portal where one can check class schedule, bill payment, viewing available courses, checking final grades, book ordering, etc.

it gives students all the convenience required for effective learning experience.

The UC ONE platform is a platform found in the portal of University of the Cumberland.

Consider two different processors P1 and P2 executing the same instruction set. P1 has a 3 GHz clock rate and a CPI of 1.5. P2 has a 3 GHz clock rate and a CPI of 1.0. Which processor has the highest performance expressed in instructions per second

Answers

Answer:

Processor P2 has the highest performance expressed in instructions per second.

Explanation:

Given:

Processors:

P1

P2

Clock rate of P1 = 3 GHz

Clock rate of P2 = 3 GHz

Cycles per instruction = CPI of P1 = 1.5

Cycles per instruction = CPI of P2 = 1.0

To find:

which processor has the highest performance in instructions per second (IPS)

Solution:

Compute CPU time:

CPU time =  (Number of instructions * cycles per instruction) / clock rate

CPU time = (I * CPI) / R

We are given the CPI and clock rate. So

CPU time = (I * CPI) / R

 I / CPU time = R/CPI

Since

Instructions per second = Number of instructions (I) / execution time

                             IPS     = I / CPU time

So

Instructions Per Second = clock rate / cycles per instruction

IPS = R/CPI

Putting the values in above formula:

Instructions Per Second for P1 = IPS (P1)

                                                  = clock rate P1 / CPI (P1)

                                                  = 3 GHz / 1.5

                                     IPS (P1) = 2            

As 1 GHz = 10⁹ Hz

IPS (P1) = 2x10⁹

Instructions Per Second for P2 = IPS (P2)

                                                  = clock rate P2 / CPI (P2)

                                                  = 3 / 1.0

                                     IPS (P2) = 3

As 1 GHz = 10⁹ Hz

IPS (P2) = 3x10⁹

Hence processor P2 has the highest performance expressed in instructions per second i.e. 3x10⁹

what makes''emerging technologies'' happen and what impact will they have on individuals,society,and environment

Answers

Answer:

Are characterized by radical novelty

Explanation:

Example, intelligent enterprises are reimaging and reinventing the way they do bussines

Write a program that reads in your question #2 Python source code file and counts the occurrence of each keyword in the file. Your program should prompt the user to enter the Python source code filename

Answers

Answer:

Here is the Python program:

import keyword  #module that contains list of keywords of python

filename = input("Enter Python source code filename: ") # prompts user to enter the filename of a source code

code = open(filename, "r") # opens the file in read mode

keywords = keyword.kwlist #extract list of all keywords of Python and stored it into keywords

dictionary = dict() #creates a dictionary to store each keyword and its number of occurrence in source code

for statement in code: # iterates through each line of the source code in the file

   statement = statement.strip() # removes the spaces in the statement of source code  

   words = statement.split(" ") #break each statement of the source code into a list of words by empty space separator

   for word in words:# iterates through each word/item of the words list  

       if word in keywords:#checks if word in the code is present in the keywords list of Python  

           if word in dictionary: #checks if word is already present in the dictionary

               dictionary[word] = dictionary[word] + 1 #if word is present in dictionary add one to the count of the existing word

           else: #if word is not already present in the dictionary  

               dictionary[word] = 1 #add the word to the dictionary and set the count of word to 1

for key in list(dictionary.keys()): #iterates through each word in the list of all keys in dictionary  

   print(key, ":", dictionary[key])# prints keyword: occurrences in key:value format of dict

Explanation:

The program is well explained in the comments attached with each line of the program.  

The program prompts the user to enter the name of the file that contains the Python source code. Then the file is opened in read mode using open() method.

Then the keyword.kwlist statement contains the list of all keywords of Python. These are stored in keywords.

Then a dictionary is created which is used to store the words from the source code that are the keywords along with their number of occurrences in the file.

Then source code is split into the lines (statements) and the first for loop iterates through each line and removes the spaces in the statement of source code .

Then the lines are split into a list of words using split() method. The second for loop is used to iterate through each word in the list of words of the source code. Now each word is matched with the list of keywords of Python that is stored in keywords. If a word in the source code of the file is present in the keywords then that word is added to the dictionary and the count of that word is set to 1. If the word is already present in the dictionary. For example if there are 3 "import" keywords in the source code and if 1 of the import keywords is already in the dictionary. So when the second import keyword is found, then the count of that keyword is increased by 1 so that becomes 2.

Then the last loop is used to print each word of the Python that is a keyword along with its number of occurrences in the file.

The program and its output is attached in a screenshot. I have used this program as source code file.

Why MUST you request your DSO signed I-20 ship as soon as it is ready and who is responsible to request the I-20

Answers

Why MUST you request your DSO signed I-20 ship as soon as it is ready and who is responsible to request the I-20?

a. It is required you have an endorsed/signed I-20 when Customs and Border Patrol or police ask for it

b. We only keep an unsigned digital copy and cannot sign an I-20 after the fact

c. It is against U.S. regulations to send digital (signed or not) DS-2019s and must treat I-20s the same

d. You will need all signed original I-20s to make copies to apply for OPT, STEM and H-1B in the future, so get them now!

e. It is the student’s choice to request each term, however, we cannot go back retroactively to provide past copies

f. We can only provide a signed copy of current I-20 and if changes occur from previous semesters that information will not show

g. The original endorsed I-20 signed by a DSO will be destroyed after 30 days of issuance if not picked up, and it cannot be replicated

h. The cost to have I-20 shipped may go up at any time

i. All the above

Answer:

i. All the above

Explanation:

DSO means designated school officials and they have to do with Student and Exchange Visitor Program (SEVP)-certified schools where students have to get a Form I-20, “Certificate of Eligibility for Nonimmigrant Student Status which provides information about the student's F or M status.

What a student must request for from his DSO signed I-20 ship are all the above options.

Write a SELECT statement that selects all of the columns for the catalog view that returns information about foreign keys. How many foreign keys are defined in the AP database?

Answers

Answer:

SELECT COUNT (DISTICT constraint_name)

FROM apd_schema.constraint_column_usage

RUN

Explanation:

General syntax to return a catalog view of information about foreign keys.

SELECT DISTINCT PARENT_TABLE =

           RIGHT(Replace(DC.constraint_name, 'fkeys_', ''),

           Len(Replace(DC.constraint_name, 'fkeys_', '')) - Charindex('_', Replace(DC.constraint_name, 'fkeys_', ''))),

           CHILD_TABLE = DC.table_name,

           CCU.column_name,

           DC.constraint_name,

           DC.constraint_type

FROM apd_schema.table_constraints DC

INNER JOIN apd_schema.constraint_column_usage CCU

           ON DC.constraint_name = CCU.constraint_name

WHERE  DC.constraint_type LIKE '%foreign'

           OR DC.constraint_type LIKE '%foreign%'

           OR DC.constraint_type LIKE 'foreign%'

RUN

You resurrected an old worksheet. It appears to contain most of the information that you need, but not all of it. Which step should you take next

Answers

Answer:

The answer is "check the worksheet is not read only"

Explanation:

The read only mode is used for read the file data, and it doesn't allows the user to update the file, and for updating the worksheet we should check iut does not open in the read-only mode.

If it is open, then we close it and for close we goto the office button and click on the tools option after that goto general setting, in this there is a check box for turn off the read-only mode.

 

Consider the following calling sequences and assuming that dynamic scoping is used, what variables are visible during execution of the last function called? Include with each visible variable the name of the function in which it was defined.a. Main calls fun1; fun1 calls fun2; fun2 calls fun3b. Main calls fun1; fun1 calls fun3c. Main calls fun2; fun2 calls fun3; fun3 calls fun1d. Main calls fun3; fun3 calls fun1e. Main calls fun1; fun1 calls fun3; fun3 calls fun2f. Main calls fun3; fun3 calls fun2; fun2 calls fun1void fun1(void);void fun2(void);void fun3(void);void main() {Int a,b,c;…}void fun1(void){Int b,c,d;…}void fun2(void){Int c,d,e;…}void fun3(void){Int d,e,f;…}

Answers

Answer:

In dynamic scoping the current block is searched by the compiler and then all calling functions consecutively e.g. if a function a() calls a separately defined function b() then b() does have access to the local variables of a(). The visible variables with the name of the function in which it was defined are given below.

Explanation:

In main() function three integer type variables are declared: a,b,c

In fun1() three int type variables are declared/defined: b,c,d

In fun2() three int type variables are declared/defined: c,d,e

In fun3() three int type variables are declared/defined: d,e,f

a. Main calls fun1; fun1 calls fun2; fun2 calls fun3

Here the main() calls fun1() which calls fun2() and fun2() calls func3() . This means first the func3() executes, then fun2(), then fun1() and last main()

Visible Variable:  d, e, f        Defined in: fun3

Visible Variable: c                 Defined in: fun2 (the variables d and e of fun2  

                                                                                                     are not visible)

Visible Variable: b                  Defined in: fun1 ( c and d of func1 are hidden)

Visible Variable: a                 Defined in: main (b,c are hidden)

b. Main calls fun1; fun1 calls fun3

Here the main() calls fun1, fun1 calls fun3. This means the body of fun3 executes first, then of fun1 and then in last, of main()

Visible Variable: d, e, f           Defined in: fun3

Visible Variable:  b, c              Defined in: fun1 (d not visible)

Visible Variable:  a                  Defined in: main ( b and c not visible)

c. Main calls fun2; fun2 calls fun3; fun3 calls fun1

Here the main() calls fun2, fun2 calls fun3 and fun3 calls fun1. This means the body of fun1 executes first, then of fun3, then fun2 and in last, of main()

Visible Variable:  b, c, d        Defined in: fun1

Visible Variable:  e, f             Defined in: fun3 ( d not visible)

Visible Variable:  a                Defined in: main ( b and c not visible)

Here variables c, d and e of fun2 are not visible

d. Main calls fun3; fun3 calls fun1

Here the main() calls fun3, fun3 calls fun1. This means the body of fun1 executes first, then of fun3 and then in last, of main()

Visible Variable: b, c, d     Defined in: fun1  

Visible Variable:   e, f        Defined in:  fun3   ( d not visible )

Visible Variable:    a          Defined in: main (b and c not visible)

e. Main calls fun1; fun1 calls fun3; fun3 calls fun2

Here the main() calls fun1, fun1 calls fun3 and fun3 calls fun2. This means the body of fun2 executes first, then of fun3, then of fun1 and then in last, of main()

Visible Variable: c, d, e        Defined in: fun2

Visible Variable:  f               Defined in: fun3 ( d and e not visible)

Visible Variable:  b               Defined in:  fun1 ( c and d not visible)

Visible Variable: a                Defined in: main ( b and c not visible)

f. Main calls fun3; fun3 calls fun2; fun2 calls fun1

Here the main() calls fun3, fun3 calls fun2 and fun2 calls fun1. This means the body of fun1 executes first, then of fun2, then of fun3 and then in last, of main()

Visible Variable: b, c, d       Defined in: fun1  

Visible Variable: e               Defined in: fun2  

Visible Variable: f                Defined in: fun3  

Visible Variable: a               Defined in: main

Can Anyone put my name in binary code using these images? Bentley is my name

Answers

Answer:

10010100001001010100101101010100000000000000000010100101010101111010001001010010100101001

Explanation:

Define a function pyramid_volume with parameters base_length, base_width, and pyramid_height, that returns the volume of a pyramid with a rectangular base. Sample output with inputs: 4.5 2.1 3.0

Answers

Answer:

def pyramid_volume(base_length,base_width,pyramid_height):

      return base_length * base_width * pyramid_height/3

length = float(input("Length: "))

width = float(input("Width: "))

height = float(input("Height: "))

print("{:.2f}".format(pyramid_volume(length,width,height)))

Explanation:

This line declares the function along with the three parameters

def pyramid_volume(base_length,base_width,pyramid_height):

This line returns the volume of the pyramid

      return base_length * base_width * pyramid_height/3

The main starts here

The next three lines gets user inputs for length, width and height

length = float(input("Length: "))

width = float(input("Width: "))

height = float(input("Height: "))

This line returns the volume of the pyramid in 2 decimal places

print("{:.2f}".format(pyramid_volume(length,width,height)))

While it might be considered "old-school," which action should you take if you are unsure how a page will print, even after looking at Page Break Preview?a) Slide the solid blue line.b) Slide the dotted line.c) Print the first page.d) Eliminate page breaks.

Answers

Answer:

The correct answer is D

In the case of printing pages when you are not sure of the number of the page the printer will print you should leave some gaps or margins or leave space between the two pages.

The old-school way to do this is by Printing the first page. Hence the option C is correct.

Learn more bout the might be considered "old-school,".

brainly.com/question/26057812.

var tax = .07;

var getCost = function(itemCost, numItems) {

var subtotal = itemCost * numItems;

var tax = 0.06;

var total = subtotal + subtotal * tax;

return (total);

}

var totalCost = getCost(25.00, 3);

alert("Your cost is $" + totalCost.toFixed(2) + " including a tax of " +

tax.toFixed(2));


Which variable represents the function expression?


a. totalCost

b. getCost

c. itemCost

d. total

Answers

Answer:

b. getCost

Explanation:

Javascript is a multi-purpose programming language, used in applications like web development, software development and embedded system programming, data visualization and analysis, etc.

Its regular syntax defines variables with the "var" keyword and with additional ecmascript rules, the "let" and "const" keywords as well. function definition uses the keyword "function" with parenthesis for holding arguments. The code block of a function is written between two curly braces and returns a value stored in a variable with the return keyword.

The variable can now be called with the parenthesis and required arguments. Note that only anonymous functions can assigned to a variable.

Assign a variable solveEquation with a function expression that has three parameters (x, y, and z) and returns the result of evaluating the expression Z-y + 2 * x. 2 /* Your solution poes here */ 4 solveEquation(2, 4, 5.5); // Code will be tested once with values 2, 4, 5.5 and again with values -5, 3, 8

Answers

Answer:

The programming language is not stated;

However, the program written in Python is as follows

def solveEquation(x,y,z):

     result = z - y + 2 * x

     print(result)

x = float(input("x = "))

y = float(input("y = "))

z = float(input("z = "))

print(solveEquation(x,y,z))

Explanation:

This line defines the function solveEquation

def solveEquation(x,y,z):

This line calculates the expression in the question

     result = z - y + 2 * x

This line returns the result of the above expression

     print(result)

The next three lines prompts user for x, y and z

x = float(input("x = "))

y = float(input("y = "))

z = float(input("z = "))

This line prints the result of the expression

print(solveEquation(x,y,z))

Using virtualization comes with many advantages, one of them being performance. Which of these is NOT another realistic advantage of using virtualization over dedicated hardware?a. There are improvements in security and high availability during outage.b. There are cost benefits.c. Maintenance and updates are simplified or eliminated.d. There are fewer points of failure.

Answers

Answer:

a. There are improvements in security and high availability during outage

Explanation:

Virtualization occurs when data that could be in several formats (for example, storage devices) are made to appear real through a software. There are virtualization providers who act as third-party between users and the original manufacturers of the software. While virtualization has received wide popularity in recent times because of the several advantages it offers of which cost-saving is included, it also has some disadvantages. One of them from the options provided is the possibility of a security breach and its uncertain availability.

The security breach arises because of the proliferation of information on the virtual space. This information can be accessed by unauthorized hackers. Also since third-party providers are the usual providers of virtualization services, the availability depends on them because if they shut down, users can no longer access the software.

Generating a signature with RSA alone on a long message would be too slow (presumably using cipher block chaining). Suppose we could do division quickly. Would it be reasonable to compute an RSA signature on a long message by first finding what the message equals (taking the message as a big integer), mod n, and signing that?

Answers

Answer:

Following are the algorithm to this question:

Explanation:

In the RSA algorithm can be defined as follows:  

In this algorithm, we select two separate prime numbers that are the "P and Q", To protection purposes, both p and q combines are supposed to become dynamically chosen but must be similar in scale but 'unique in length' so render it easier to influence. Its value can be found by the main analysis effectively.  

Computing N = PQ.  

In this, N can be used for key pair, that is public and private together as the unit and the Length was its key length, normally is spoken bits. Measure,

[tex]\lambda (N) = \ lcm( \lambda (P), \lambda (Q)) = \ lcm(P- 1, Q - 1)[/tex]  where [tex]\lambda[/tex] is the total function of Carmichaels. It is a privately held value. Selecting the integer E to be relatively prime from [tex]1<E < \lambda (N)[/tex]and [tex]gcd(E, \lambda (N) ) = 1;[/tex] that is [tex]E \ \ and \ \ \lambda (N)[/tex].  D was its complex number equivalent to E (modulo [tex]\lambda (N)[/tex] ); that is d was its design multiplicative equivalent of E-1.  

It's more evident as a fix for d provided of DE ≡ 1 (modulo [tex]\lambda (N)[/tex] ).E with an automatic warning latitude or little mass of bigging contribute most frequently to 216 + 1 = 65,537 more qualified encrypted data.

In some situations it's was shown that far lower E values (such as 3) are less stable.  

E is eligible as a supporter of the public key.  

D is retained as the personal supporter of its key.  

Its digital signature was its module N and the assistance for the community (or authentication). Its secret key includes that modulus N and coded (or decoding) sponsor D, that must be kept private. P, Q, and [tex]\lambda (N)[/tex] will also be confined as they can be used in measuring D. The Euler totient operates [tex]\varphi (N) = (P-1)(Q - 1)[/tex] however, could even, as mentioned throughout the initial RSA paper, have been used to compute the private exponent D rather than λ(N).

It applies because [tex]\varphi (N)[/tex], which can always be split into  [tex]\lambda (N)[/tex], and thus any D satisfying DE ≡ 1, it can also satisfy (mod  [tex]\lambda (N)[/tex]). It works because [tex]\varphi (N)[/tex], will always be divided by [tex]\varphi (N)[/tex],. That d issue, in this case, measurement provides a result which is larger than necessary (i.e. D >   [tex]\lambda (N)[/tex] ) for time - to - time). Many RSA frameworks assume notation are generated either by methodology, however, some concepts like fips, 186-4, may demand that D<   [tex]\lambda (N)[/tex]. if they use a private follower D, rather than by streamlined decoding method mostly based on a china rest theorem. Every sensitive "over-sized" exponential which does not cooperate may always be reduced to a shorter corresponding exponential by modulo  [tex]\lambda (N)[/tex].

As there are common threads (P− 1) and (Q – 1) which are present throughout the [tex]N-1 = PQ-1 = (P -1)(Q - 1)+ (P-1) + (Q- 1))[/tex], it's also possible, if there are any, for all the common factors [tex](P -1) \ \ \ and \ \ (Q - 1)[/tex]to become very small, if necessary.  

Indication: Its original writers of RSA articles conduct their main age range by choosing E as a modular D-reverse (module [tex]\varphi (N)[/tex]) multiplying. Because a low value (e.g. 65,537) is beneficial for E to improve the testing purpose, existing RSA implementation, such as PKCS#1, rather use E and compute D.

How does the teacher know you have completed your assignment in Google Classroom?

Answers

Answer:

When students have completed the assignment, they simply click the Mark As Done button to let the teacher know they have finished.

Explanation: Note: The teacher does NOT receive an alert or email notification when work has been turned in, or marked as done.

Other Questions
What is the difference between effect and affect? pls provide with some good examples as well:) For the following reaction, 61.6 grams of bromine are allowed to react with 25.5 grams of chlorine gas. bromine (g) + chlorine (g) bromine monochloride (g) What is the maximum amount of bromine monochloride that can be formed? grams The Sherman Antitrust Act of 1890 was successful enough in reducing the power of cartels and monopolies that no further legislation to curb monopoly power has ever been needed.a. Trueb. False Choose the vocabulary word that goes with the other words in the group.La iglesia, el templo,la bibliotecala bodala celebracinla mezquita What is 45x62 Please help. Carey earns $9.75 working part time on weekends. The table below shows the amount, a, Carey earns for working h hours. Careys Earnings h 0 1 3 a $0 $9.75 ? Which value completes the table to show the amount Carey earns for working 3 hours? Assume that you are provided with the following materials: Strips of metallic zinc, metallic copper, metallic iron 1M aqueous solutions of ZnSO4, CuSO4, FeSO4, and aqueous iodine(I2) Other required materials to create Voltaic cells such as beakers, porous containers, graphite rods, a voltmeter, and a few wires with alligator clips.In this modified version of the lab, after thoroughly studying the lab hand out and watching the videos,identify 4 different combinations of Voltaic cells that are possible to be created with the above materials.For each cell created, include the following details. A) Which electrode was the anode,and which was the Cathode? B) The anode and cathode half reactions. C) Balanced equation for each cell you propose to construct. D) Calculated Eocelle Short hand notation (line notation) for each cell (be sure to include the inactive electrode if needed). literary theme is defined as the series of events that construct a tale. the message a text conveys about a topic. the location where a text takes place. the author's opinion of previous experiences. PLEASE HELP Give me an example of a negative correlation What best explains whether a triangle with side links 5 cm 13 cm and 12 cm is a right triangle What is Noah Joads dream in the Grapes of Wrath? George wanted a home in the St. Paul area. He was willing to pay premium price for it even though there were other homes in other areas that were better values. When George was asked why he was willing to pay so much, he told the sales associate that he worked in that area and that he wanted his children to attend school in a specific school district. George's willingness to pay top dollar for a home in St. Paul is because of which characteristic of value? How did William H. Seward aid US expansion?Seward sent missionaries to Hawaii to spread US culture.Seward concluded the first US treaty with Japan.Seward negotiated the end of the Russo-Japanese War.Seward signed a treaty with Russia to buy Alaska the origin of a muscle is generally Please answer this question now PLS HELP ASAP:Find all the missing elements: It seems almost unbelievable that so many students are sick during midterms and final exams, but actually these are times of _________ stress that _________ the effectiveness of the immune system to fight off illness. Group of answer choices Which of the following railroads was not one of the first four major railroads built in the Indian Territory? A. the Missouri-Kansas-Texas Railroad B. the Atlantic and Pacific Railway C. the Central Pacific Railroad D. the Chicago, Rock Island, and Pacific Railroad What financial institution is in charge of monitoring the stock market today? A. Federal Deposit Insurance Corporation B. Social Security Administration C. US Treasury Department D. Securities and Exchange Commission Directions: Calculate the percent increase or decrease between the starting and endingquantities below. Round your answer to one decimal place.1. Start: 3End: 102. Start: 9End: 203. Start: 100End: 854. Start: 45End: 205. Start: 30End: 60