In this assignment, you will implement an online banking system. Users can sign-up with the system, log in to the system, change their password, and delete their account. They can also update their bank account balance and transfer money to another user’s bank account.
You’ll implement functions related to File I/O and dictionaries. The first two functions require you to import files and create dictionaries. User information will be imported from the "users.txt" file and account information will be imported from the "bank.txt" file. Take a look at the content in the different files. The remaining functions require you to use or modify the two dictionaries created from the files.
Each function has been defined for you, but without the code. See the docstring in each function for instructions on what the function is supposed to do and how to write the code. It should be clear enough. In some cases, we have provided hints to help you get started.
def import_and_create_dictionary(filename):
'''
This function is used to create a bank dictionary. The given argument is the filename to load.
Every line in the file will look like
key: value
Key is a user's name and value is an amount to update the user's bank account with. The value should be a
number, however, it is possible that there is no value or that the value is an invalid number.
What you will do:
- Try to make a dictionary from the contents of the file.
- If the key doesn't exist, create a new key:value pair.
- If the key does exist, increment its value with the amount.
- You should also handle cases when the value is invalid. If so, ignore that line and don't update the dictionary.
- Finally, return the dictionary.
Note: All of the users in the bank file are in the user account file.
'''
d = {}
# your code here
return d
##########################
### TEST YOUR SOLUTION ###
##########################
bank = import_and_create_dictionary("bank.txt")
tools.assert_false(len(bank) == 0)
tools.assert_almost_equal(115.5, bank.get("Brandon"))
tools.assert_almost_equal(128.87, bank.get("James"))
tools.assert_is_none(bank.get("Joel"))
tools.assert_is_none(bank.get("Luke"))
tools.assert_almost_equal(bank.get("Sarah"), 827.43)
#user.txt
Brandon - brandon123ABC
Jack
Jack - jac123
Jack - jack123POU
Patrick - patrick5678
Brandon - brandon123ABCD
James - 100jamesABD
Sarah - sd896ssfJJH
Jennie - sadsaca
#bank.txt
Brandon: 5
Patrick: 18.9
Brandon: xyz
Jack:
Sarah: 825
Jack : 45
Brandon: 10
James: 3.25
James: 125.62
Sarah: 2.43
Brandon: 100.5

Answers

Answer 1

Answer:

# global variable for logged in users

loggedin = []

# create the user account list as a dictionary called "bank".

def import_and_create_dictionary(filename):

   bank = {}

   i = 1

   with open(filename, "r") as file:

       for line in file:

           (name, amt) = line.rstrip('\n').split(":")

           bank[i] = [name.strip(), amt]

           i += 1

   return bank

#create the list of user login details.

def import_and_create_accounts(filename):

   acc = []

   with open(filename, "r") as file:

       for line in file:

           (login, password) = line.rstrip('\n').split("-")

           acc.append([login.strip(), password.strip()])

   return acc

# function to login users that are yet to login.

def signin(accounts, login, password):

   flag="true"

   for lst in accounts:

       if(lst[0]==login and lst[1] == password):

           for log in loggedin:

               if(log ==login):

                    print("You are already logged in")

                    flag="false"

           break                    

       else:

           flag="false"  

   if(flag=="true"):

       loggedin.append(login) # adding user to loggedin list

       print("logged in succesfully")

       return True

   return False

# calling both the function to create bank dictionary and user_account list        

bank  = import_and_create_dictionary("bank.txt")            

print (bank)

user_account = import_and_create_accounts("user.txt")

print(user_account)

# check for users loggedin

signin(user_account,"Brandon","123abcAB")

signin(user_account,"James","100jamesABD")

signin(user_account,"Sarah","sd896ssfJJH")

Explanation:

The python program is a banking application system that creates a list of user accounts and their login details from the bank.txt and user.txt file. The program also uses the information to log in and check for users already logged into their account with the "loggedin" global variable.

Answer 2

In this exercise we have to use the knowledge of programming in the python language, in this way we find that the code can be written as:

The code can be seen in the attached image.

To make it even simpler to visualize the code, we can rewrite it below as:

def import_and_create_dictionary(filename):

  bank = {}

  i = 1

  with open(filename, "r") as file:

      for line in file:

          (name, amt) = line.rstrip('\n').split(":")

          bank[i] = [name.strip(), amt]

          i += 1

  return bank

#create the list of user login details.

def import_and_create_accounts(filename):

  acc = []

  with open(filename, "r") as file:

      for line in file:

          (login, password) = line.rstrip('\n').split("-")

          acc.append([login.strip(), password.strip()])

  return acc

def signin(accounts, login, password):

  flag="true"

  for lst in accounts:

      if(lst[0]==login and lst[1] == password):

          for log in loggedin:

              if(log ==login):

                   print("You are already logged in")

                   flag="false"

          break                  

      else:

          flag="false"  

  if(flag=="true"):

      loggedin.append(login) # adding user to loggedin list

      print("logged in succesfully")

      return True

  return False

bank  = import_and_create_dictionary("bank.txt")      

print (bank)

user_account = import_and_create_accounts("user.txt")

print(user_account)

signin(user_account,"Brandon","123abcAB")

signin(user_account,"James","100jamesABD")

signin(user_account,"Sarah","sd896ssfJJH")

See more about programming at brainly.com/question/11288081

In This Assignment, You Will Implement An Online Banking System. Users Can Sign-up With The System, Log

Related Questions

9. Select the correct answer.
Jude has entered into an agreement with his client regarding the use of his images over a span of five years. They have agreed that the images will not be shared with any other clients. Which type of usage has Jude agreed to in this contract between himself and the client?
A.
non-exclusive
B.
exclusive
C.
fair use
D.
copyright
E.
statutory

Answers

Answer:

I believe the answer is exclusive but im not 100% sure

Answer:

The answer is choice B. Exclusive.

Explanation:

Security attacks are classified as either passive or aggressive. True or false

Answers

Answer:

false is the answer okkkkkkkkkkkkkkkk

From which of the following locations can you run a single line of the program?
Manual Movement dialog box
RoboCell toolbar
Program toolbar
Run menu
I’m in manufacturing and I don’t like this class it has nothing to do with what I wanna do so can someone help please

Answers

RoboCell toolbar and Run menu

It's important to understand that even information systems that do not use computers
have a software resource component. State the two (2) types of software resources
with an example for each type to support your answers.

Answers

Answer:

yes I am not sure if you have any questions or concerns please visit the plug-in settings to determine how attachments are handled the situation in the measurements of the season my dear friend I am not sure if you can send you a great day to day basis of

help me in computer

no spam i will report wrong answer​

Answers

In the computar process it has to be done in a blind fold

Write a function longer_string() with two string input parameters that returns the string that has more characters in it. If the strings are the same size, return the string that occurs later according to the dictionary order. Use the function in a program that takes two string inputs, and outputs the string that is longer.

Answers

Answer:

Here you go :)

Explanation:

Change this to your liking:

def longer_string(s1, s2):

   if len(s1) > len(s2):

       return s1

   elif len(s1) < len(s2):

       return s2

   else:

       return s2

x = input("Enter string 1: ")

y = input("Enter string 2: ")

print(longer_string(x, y))

Let us say numbers.txt contains the sequence of numbers from 1 to 10000, like this:
1
2
3
4
Each of the following 2 commands should output the following 4 lines. Complete the commands with correct values to make it happen!
4377
4378
4379
4380
head - numbers.txt | tail -
tail - numbers.txt | head -

Answers

Answer:

Follows are the solution to this question:

Explanation:

head | tail -n 4380 in the numbers.txt

This will take first 4380 lines head -n 4380

tail -n 4 takes out the last 4 lines

tail -n + 4377.txt | head -n 4 -n

tail -n + 4377 requires all 4377 lines

head -n 4 cuts out first four lines

that's why the final answer is "4380, 4 5624,4".

Suppose that an intermixed sequence of push and pop operations are performed on a LIFO stack. The pushes push the numbers 0 through 9 in order; the pops print out the return value. For example"push(0); pop(); push(1)" and "push(0); push(1); pop()" are possible, but "push(1); push(0); pop()" is not possible, because 1 and 0 are out of order. Which of the following output sequence(s) could occur? Select all that are possible.
a) 12543 609 8 7 0
b) 01564 37928
c) 6543210789
d) 02416 75983
e) 46 8 75 32 901

Answers

Answer:

b) 01564 37928

e) 26 8 75 32 901

Explanation:

Pushes and pulls are the computer operations which enable the user to perform numerical tasks. The input commands are interpreted by the computer software and these tasks are converted into numeric values to generate output.

Your goal is to write a JAVA program that will ask the user for a long string and then a substring of that long string. The program then will report information on the long string and the substring. Finally it will prompt the user for a replacement string and show what the long string would be with the substring replaced by the replacement string. Each of the lines below can be produced by using one or more String methods - look to the String method slides on the course website to help you with this project.
A few sample transcripts of your code at work are below - remember that your code should end with a newline as in the textbook examples and should produce these transcripts exactly if given the same input. Portions in bold indicate where the user has input a value.
One run of your program might look like this:
Enter a long string: The quick brown fox jumped over the lazy dog
Enter a substring: jumped
Length of your string: 44
Length of your substring: 6
Starting position of your substring: 20
String before your substring: The quick brown fox
String after your substring: over the lazy dog
Enter a position between 0 and 43: 18
The character at position 18 is x
Enter a replacement string: leaped
Your new string is: The quick brown fox leaped over the lazy dog
Goodbye!
A second run with different user input might look like this:
Enter a long string: Friends, Romans, countrymen, lend me your ears
Enter a substring: try
Length of your string: 46
Length of your substring: 3
Starting position of your substring: 21
String before your substring: Friends, Romans, coun
String after your substring: men, lend me your ears
Enter a position between 0 and 45: 21
The character at position 21 is t
Enter a replacement string: catch
Your new string is: Friends, Romans, councatchmen, lend me your ears
Goodbye!

Answers

Answer:

In  Java:

import java.util.*;

public class Main{

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 String longstring, substring;

 System.out.print("Enter a long string: ");

 longstring = input.nextLine();

 System.out.print("Enter a substring: ");

 substring = input.nextLine();

 

 System.out.println("Length of your string: "+longstring.length());

 System.out.println("Length of your substring: "+substring.length());

 System.out.println("Starting position of your substring: "+longstring.indexOf(substring));

 

 String before = longstring.substring(0, longstring.indexOf(substring));

 System.out.println("String before your substring: "+before);

 

 String after = longstring.substring(longstring.indexOf(substring) + substring.length());

 System.out.println("String after your substring: "+after);

 

 System.out.print("Enter a position between 0 and "+(longstring.length()-1)+": ");

 int pos;

 pos = input.nextInt();

 System.out.println("The character at position "+pos+" is: "+longstring.charAt(pos));

 

 System.out.print("Enter a replacement string: ");

 String repl;

 repl = input.nextLine();

 

 System.out.println("Your new string is: "+longstring.replace(substring, repl));

 System.out.println("Goodbye!");

}

}

Explanation:

Because of the length of the explanation; I've added the explanation as an attachment where I used comments to explain the lines

In this exercise we have to use the knowledge of the JAVA language to write the code, so we have to:

The code is in the attached photo.

So to make it easier the JAVA code can be found at:

import java.util.*;

public class Main{

public static void main(String[] args) {

Scanner input = new Scanner(System.in);

String longstring, substring;

System.out.print("Enter a long string: ");

longstring = input.nextLine();

System.out.print("Enter a substring: ");

substring = input.nextLine();

System.out.println("Length of your string: "+longstring.length());

System.out.println("Length of your substring: "+substring.length());

System.out.println("Starting position of your substring: "+longstring.indexOf(substring));

String before = longstring.substring(0, longstring.indexOf(substring));

System.out.println("String before your substring: "+before);

String after = longstring.substring(longstring.indexOf(substring) + substring.length());

System.out.println("String after your substring: "+after);

System.out.print("Enter a position between 0 and "+(longstring.length()-1)+": ");

int pos;

pos = input.nextInt();

System.out.println("The character at position "+pos+" is: "+longstring.charAt(pos));

System.out.print("Enter a replacement string: ");

String repl;

repl = input.nextLine();

System.out.println("Your new string is: "+longstring.replace(substring, repl));

System.out.println("Goodbye!");

}

}

See more about JAVA at brainly.com/question/2266606?

How can we display outputs of DIR one screenful at a time? There are at least two different ways, and either one is acceptable.

Answers

Answer:

DIR has a /p option to paginate any output.

dir /p

Will give you one screen length at a time.

I believe you can use that simultaneously with /w if you want to fit more file names on the screen, at the loss of additional data like file size, type, etc.

Which statement about creating a client request in quickbooks online accountant is false

Answers

Answer:

You can add attachments by selecting the + Add document link

The request is not sent to the client's email address unless the default setting is changed.

The request appears in the client's QuickBooks Online company in My Accountant

If you wish to notify your client of your request with a QuickBooks Online-generated email, select Notify client

Explanation:

The highlighted one is correct. Its QBO question.

Your supervisor has asked you to make a presentation to a group of new interns about appropriate digital communication in the workplace. Which of these keywords should you research?

A netiquette

B project management

C emojis

Answers

Answer: Netiquette

Explanation:

The keywords that'll be researched is netiquette. Netiquette, is simply made up of the words "net"which and also “etiquette,” and it has to do with appropriate behavior that are used online when communicating with someone. These importance of such rules are to enhance communication skills.

Some of the rules include the use of respectful language, large files should not be emailed but rather compressed, people's privacy should be respected etc

3. What workplace hazards can be found on picture A?

4-5. Describe the workplace A and B, What are their differences​

Answers

Answer:

Hakdog

Explanation:

kase hakdog ka kainin mo tite ko

Write an algorithm to show whether a given number is even or odd.

Answers

Answer:

int num = Console.ReadInt("Please enter a number");

if(num%2 == 0) {

Console.WriteLine("Number is even");

} else {

Console.WriteLine("Number is odd");

Explanation:

10. Select the correct answer.
Thomas has signed a deal with a production house that allows them to use his images on their website. What is required that permits the usage of images for commercial or editorial purposes?
A.
copyright
B.
licensing
C.
permit
D.
public domain
E.
fair use

Answers

b) licensing because they are giving Thomas permission to use the images
B is the correct answer .!!!!!

Consider the following statements: Statement A: In Duplex transmission, either node can transmit while the other node can receive data Statement B: In half-duplex transmission, both the nodes can transmit as well as receive data at the same time. Which of the following is true with respect to the above statements?

a. Both statements A and B are false
b. Statement A is false and statement B is true
c. Both statements A and B are true
d. Statement A is true and statement B is false

Answers

Answer:

d. Statement A is true and Statement B is false

Explanation:

Indeed, when using duplex transmission either node can transmit while the other node can receive data from the network. Also, in half-duplex transmission, both the nodes can transmit as well as receive data.

However, in half-duplex transmission, the nodes cannot transmit and receive data at the same time. Hence, this makes Statement B false, while Statement A is true.

.............................................is the vertical distance between successive lines of the text​

Answers

Answer:

Line spacing is the vertical distance between successive lines of the text​.

Explanation:

Hope this helps you. :)

What devices do not form part of the main components of a computer but can be attached to function effectively?

Answers

Answer:

Peripherals are a generic name for any device external to a computer, but still normally associated with its extended functionality. The purpose of peripherals is to extend and enhance what a computer is capable of doing without modifying the core components of the system. A printer is a good example of a peripheral.

Explanation:

Now, it’s time for you to begin coding your text-based adventure game!Starting at the top, convert each line of your pseudocode from your Coding Log into a line of Python code.Make sure to use the correct syntax and indentation. If you decide to challenge yourself and use functions, be sure to include the correct function calls.Your code should include at least two loops—one while loop and one for loop.Run and test your code in parts as you go. Follow the iterative process of coding and revising. It may be helpful to apply this process to each part of your game (Intro, Part 1, Part 2, and Part 3).Make the following improvements to your game:If the user types in a slightly different word than you expect, you don’t want your game to crash! Use lists to gain a better understanding of the input that users give. Refer back to Unit 1 for more information on lists. Here is an example:if choice in [“set a trap”, “set trap”, “trap”, “make a trap”, “make trap”]Your list won’t work if the user capitalizes any letter because the Interpreter won’t recognize a match between the same lowercase and uppercase letter. To convert the user input to all lowercase, use the lower function:if choice.lower() in [“set a trap”, “set trap”, “trap”, “make a trap”, “make trap”]Go through and make sure all of your inputs are converted to lowercase.Share the link to your Python code with your teacher in REPL.it by clicking on the share button and copying the link. Also, submit your pseudocode.

Answers

Answer:

When I finish I will send answer.

Explanation:

The coding exercise tests the ability to code using Python. It is important to note that all the indentation rules must be observed while running this code to prevent Indentation Error.



What is the code for the above exercise?

The code for the above exercise is given as follows:


def start():

# give some prompts.

 print("\nYou are standing in a dark room.")

print("There is a door to your left and right, which one do you take? (l or r)")

# convert the player's input() to lower_case

answer = input(">").lower()

if "l" in answer:

# if player typed "left" or "l" lead him to bear_room()

 bear_room()

elif "r" in answer:

# else if player typed "right" or "r" lead him to monster_room()

 monster_room()

else:

# else call game_over() function with the "reason" argument

 game_over("Don't you know how to type something properly?")

# start the game

start()


Learn more about python at:
https://brainly.com/question/26497128

#SPJ2

Where or what website can I download anime's? For free ​

Answers

https://todo-anime.com/

Write a program to calculate the total price for car wash services. A base car was is $10. A dictionary with each additional service and the corresponding cost has been provided. Two additional services can be selected. A '-' signifies an additional service was not selected. Output all selected services along with the corresponding costs and then the total price for all car wash services.Ex: If the input is:Tire shineWaxthe output is:ZyCar WashBase car wash -- $10Tire shine -- $2Wax -- $3----Total price: $15Ex: If the input is:Rain repellent-the output is:ZyCar WashBase car wash -- $10Rain repellent -- $2----Total price: $12services = { 'Air freshener' : 1 , 'Rain repellent': 2, 'Tire shine' : 2, 'Wax' : 3, 'Vacuum' : 5 }base_wash = 10total = 0service_choice1 = input()service_choice2 = input()''' Type your code here '''

Answers

Answer:

Replace

''' Type your code here '''

with the following lines of code:

price1 = services[service_choice1]

price2 = 0

if not (service_choice2 == "-"):

   price2 = services[service_choice2]

total = base_wash + price1 + price2

print("Zycar Wash")

print("Base car wash: $"+str(base_wash))

print(service_choice1+str(": $")+str(price1))

print(service_choice2+str(": $")+str(price2))

print("Total price: $"+str(total))

Explanation:

The complete program with explanation is as follows:

The italicized lines were originally part of the question

services = { 'Air freshener' : 1 , 'Rain repellent': 2, 'Tire shine' : 2, 'Wax' : 3, 'Vacuum' : 5 }

base_wash = 10

total = 0

service_choice1 = input()

service_choice2 = input()

This line gets the price of service choice 1

price1 = services[service_choice1]

This line initialzes price of service choice 2 to 0

price2 = 0

If an additional service (i.e. service choice 2) is selected

if not (service_choice2 == "-"):

This line gets the price of service choice 2

   price2 = services[service_choice2]

This calculates the total price

total = base_wash + price1 + price2

This prints the header

print("Zycar Wash")

This prints the base car wash

print("Base car wash: $"+str(base_wash))

This prints the service choice 1

print(service_choice1+str(": $")+str(price1))

This prints the service choice 2

print(service_choice2+str(": $")+str(price2))

This prints the total

print("Total price: $"+str(total))

Who manages the team’s work during a sprint?
a) Scrum master manages the people so they can complete the work
b) The team manages the work by self organization
c) Product owner manages the work
d) Delivery manger manages the work

Answers

Answer:

d) delivery manger manages the work

Explanation:

sana po makatulong ako daghay salamat sayo emo

Your first submission for the CIS 210 Course Project should include the following functionality: - Requests the user to input his/her first name - Formats the name to capitalize the first letter and makes all remaining characters lowercase, removing any spaces or special characters - Output the formatted name to the console

Answers

Answer:

In Java:

import java.util.*;

public class Main{

public static void main(String[] args) {

 Scanner input = new Scanner(System.in);

 String name;

 System.out.print("First name: ");

 name = input.next();

 name= name.substring(0, 1).toUpperCase() + name.substring(1).toLowerCase();

 System.out.print(name);

}

}

Explanation:

This declares name as string

 String name;

This prompts the user for first name

 System.out.print("First name: ");

This gets the name from the user

 name = input.next();

This capitalizes the first letter of name and makes the other letters to be in lowercase

 name= name.substring(0, 1).toUpperCase() + name.substring(1).toLowerCase();

This prints the formatted name

 System.out.print(name);

Mad Libs are activities that have a person provide various words, which are then used to complete a short story in unexpected (and hopefully funny) ways.
Write a program that takes a string and integer as input, and outputs a sentence using those items as below. The program repeats until the input string is quit.
Ex: If the input is:
apples 5
shoes 2
quito 0
the output is
Eating 5 apples a day keeps the doctor away.
Eating 2 shoes a day keeps the doctor away.
Note: This is a lab from a previous chapter that now requires the use of a loop. LB 334 1 LAB Mad Lib-loops main.cpp Load default template.
1 #include
2 #include
3 using namespace std;
4
5 int main()
6
7 {
8 return;
9
10

Answers

Answer:

Following are the code to this question:

#include <iostream>//header file

#include <string>//header file

using namespace std;

int main() //main method

{

   string item;//defining a string variable

   int n;//defining integer variable

   while(cin >>n >>item)//defining while loop to input value  

   {

       if(item == "quito" && n == 0)//use if block to check input value  

       {

           break;//use break keyword

       }

       cout << "Eating " << n << " " << item << " a day keeps the doctor away." << endl;//print input value with the message

   }

   return 0;

}

Output:

Please find the attached file.

Explanation:

In this code, inside the main method one string variable and one integer variable "item, n" is defined, that uses the while loop for input the value and uses the if block that checks string value is equal to "quito" and n value is equal to "0" it breaks the loop, and print the value with the message.

Help ASAP please This is a skills lab simulation for college, it’s on Microsoft word is there a keyboard shortcut or something on Ribbon tab to remove widow/orphan control option

Answers

Answer:

down right corner

Explanation:

next to the time

Type the correct answer in the box. Spell all words correctly.
Graphic designers can compress files in different formats. One of the formats ensures that the quality and details of the image are not lost when the graphic designer saves the file. Which file format is this?
The _______file format ensures that images don’t lose their quality and details when graphic designers save them.

Answers

Answer: TIFF

Explanation:

Tag Image File Format (TIFF) is the go to file format when one needs to store their image without worrying about it losing its quality and details. This is why TIFF images do not become smaller when compressed because they aim to save the quality of the work.

One has access to options such as tags and transparency on TIFF and it can be used on Photoshop as well as for things like desktop publishing and faxing.

Answer:

The lossless file format ensures that images don’t lose their quality and details when photographers save them.

Explanation:

How does Kelvin inspire other

people?

He shows that it's easy to meet an

important leader of a country

He shows that anyone can succeed in

the music business.

He shows that studying engineering

leads to good jobs.

He shows that hard work and creative

thinking can solve problems.

Answers

Answer:

hard work and creative thinking can solve all problomes

Explanation:

Answer:

hard work

Explanation:

Retype each statement to follow the good practice of a single space around operators.

a. tot = num1+num2+2;
b. numBalls=numBalls+1;
c. numEntries = (userVal+1)*2;

Answers

Answer:

a. tot = num1 + num2 + 2;

b. numBalls = numBalls + 1;

c. numEntries = (userVal + 1) * 2;

Explanation:

Given

(a), (b) and (c)

Require:

Rewrite

There isn't much to do or explain; All you need to do is include single space between the operands and opcodes

So:

tot = num1+num2+2;   becomes tot = num1 + num2 + 2;

numBalls=numBalls+1; becomes numBalls = numBalls + 1;

numEntries = (userVal+1)*2; becomes  numEntries = (userVal + 1) * 2;

The difference in both statements is the inclusion of single line spacing.

Declare and implement a function called gameOver.gameOver receives a single 3x3 char[] [] array as a parameter, representing a tic-tac-toe board, with each cell containing either a X, a 0, or a (blank space). gameOver should return x if x has won the game, o ifo has won the game, and a blank space (' ') otherwise. Do not check the diagonals!

Answers

Answer:

The function in C++ is as follows:

char gameOver(char arr[][3]){

   char winner = ' ';

   if((arr[0][0] == 'X' && arr[0][1] == 'X' && arr[0][2] == 'X') ||(arr[1][0] == 'X' && arr[1][1] == 'X' && arr[1][2] == 'X') || (arr[2][0] == 'X' && arr[2][1] == 'X' && arr[2][2] == 'X')||(arr[0][0] == 'X' && arr[1][0] == 'X' && arr[2][0] == 'X') ||(arr[0][1] == 'X' && arr[1][1] == 'X' && arr[2][1] == 'X') || (arr[0][2] == 'X' && arr[1][2] == 'X' && arr[2][2] == 'X')){

       winner = 'X';

   }

   else if((arr[0][0] == 'O' && arr[0][1] == 'O' && arr[0][2] == 'O') ||(arr[1][0] == 'O' && arr[1][1] == 'O' && arr[1][2] == 'O') || (arr[2][0] == 'O' && arr[2][1] == 'O' && arr[2][2] == 'O')||(arr[0][0] == 'O' && arr[1][0] == 'O' && arr[2][0] == 'O') ||(arr[0][1] == 'O' && arr[1][1] == 'O' && arr[2][1] == 'O') || (arr[0][2] == 'O' && arr[1][2] == 'O' && arr[2][2] == 'O')){

       winner = 'O';

   }

   return winner;

}

Explanation:

The function checks for the winning character by checking for matching rows and matching columns.

When either X or O fall in the any of the following 6 conditions , then that character (X or O) wins.

The position are:

Rows: (1) 00, 01 and 02 (2) 10, 11 and 12 (3) 20, 21 and 22

Columns: (4) 00, 10 and 20 (5) 01, 11 and 21 (6) 02, 12 and 22

So, the explanation is:

This defines the function gameOver

char gameOver(char arr[][3]){

This initializes winner to blank space

   char winner = ' ';

If any of the condition stated above matches X, then X wins

   if((arr[0][0] == 'X' && arr[0][1] == 'X' && arr[0][2] == 'X') ||(arr[1][0] == 'X' && arr[1][1] == 'X' && arr[1][2] == 'X') || (arr[2][0] == 'X' && arr[2][1] == 'X' && arr[2][2] == 'X')||(arr[0][0] == 'X' && arr[1][0] == 'X' && arr[2][0] == 'X') ||(arr[0][1] == 'X' && arr[1][1] == 'X' && arr[2][1] == 'X') || (arr[0][2] == 'X' && arr[1][2] == 'X' && arr[2][2] == 'X')){

       winner = 'X';

   }

If otherwise that it matches O, then O wins

   else if((arr[0][0] == 'O' && arr[0][1] == 'O' && arr[0][2] == 'O') ||(arr[1][0] == 'O' && arr[1][1] == 'O' && arr[1][2] == 'O') || (arr[2][0] == 'O' && arr[2][1] == 'O' && arr[2][2] == 'O')||(arr[0][0] == 'O' && arr[1][0] == 'O' && arr[2][0] == 'O') ||(arr[0][1] == 'O' && arr[1][1] == 'O' && arr[2][1] == 'O') || (arr[0][2] == 'O' && arr[1][2] == 'O' && arr[2][2] == 'O')){

       winner = 'O';

   }

This returns the winner (either O, X or blank)

   return winner;

See attachment for complete program which includes the main

Define the meaning of software quality and detail the factors which affects the quality not productivity of a software product?

Answers

Answer:

Quality of software may be defined as the need of function and Efficiency. ... A number of factors are given below which gives the effects on quality and production capacity.

Software quality is known to be the method that tells the desirable characteristics of software products.

What are the Software Quality Factors that affects it?

The factors that influence software are;

CorrectnessReliabilityEfficiencyUsability, etc.

Therefore, Software quality is known to be the method that tells the desirable characteristics of software products.

Learn more about software quality from

https://brainly.com/question/13262395

#SPJ2

Other Questions
Find the height of a cuboid whose volume is 540 cu.cm and base area is 90 sq.cm . Francine is dragging a heavy toolbox across a rough, cement floor.What is a contact force that is acting on the box as Francine pulls it. A. static electricity B. gravity C. magnetism D. friction __+7=2?(Postive 7^) Elena sat at her computer to write a paper. It was due onFriday and she had no idea how to start. Her topic was onthe rainforest, but Elena had never seen one. She decidedto research rainforests on the internet first.Which of the following is an inference you could make from the text?A. Elena has a paper due about the rainforest.B. Elena needs a tutor.C. It is before Friday.D. Elena hates the rainforest. Tuna Corporation reported pretax book income of $1,008,000. During the current year, the net reserve for warranties increased by $29,000. In addition, book depreciation exceeded tax depreciation by $108,000. Finally, Tuna subtracted a dividends received deduction of $19,000 in computing its current-year taxable income. Book equivalent of taxable income is: Shape p is translated to shape Q using vector (a b). Write down the values of a and b. Photo attached. If you can help me with Slope Intercept plz help me Complete each sentence using the drop-down menu. simple machines are in a mousetrap Pls help me I will mark no need explanation Is there a better way of saying, " Ever since is mother died he became a monster " Which of the following compounds is formed by a covalent bond?a. C6H12O6 b. NaBr c. CaCI2 d. NaCI A spaceship to the moon covered the 386,400 km in 72 hours. What was the average speed? Which of the following BEST completes the sentence? A writers perspective _____________________ . a. affects the direction that a biography takes b. influences the way others write about the subject c. interferes with the credibility of the biography d. is usually stated at the beginning of a biography HURRRYYYYYWhat are the most common symptoms of anemia? Select all that apply.bloatingheadachesfatigueitchy skinpale skin Write formula for the following mathematical statement.The force acting on a body is equal to the product of the mass of the body and the acceleration produced by it The picture to the right is the crystal of adiamond. Circle three individual atoms ofcarbonAre these the same type or differentatoms? Identify the choice that best completes the statement.Economic models:_______.a. cannot be useful if they are based on false assumptionsb. were once thought to be useful, but that is no longer true.c. must incorporate all aspects of the economy if they are to be useful.d. can be useful, even if they are not particularly realistic. Which kingdoms include organisms that create cellular energy (ATP) through respiration?I. ArchaebacteriaII. FungiIII. PlantaeIV. AnimaliaV. ProtistaVI. Eubacteria A. II and IV only B. I and VI only C. I, II, IV, V, and VI only D. I, II, III, IV, V, and VI sedimentary rocks are formed from weathering material that have been eroded and then deposited in layers. This process requires: a) temperature and time b) deposition and melting c) collection and transportation d) time and pressure