Peter is legitimately terminated from AM, Inc. located in Illinois. The company's reason for termination was a reduction-in-force, which resulted in the elimination of Peter's position. He is eligible for unemployment compensation benefits. The Department of Employment Security has notified Peter that his eligibility provides for up to twenty-six weeks of unemployment compensation benefits.
Peter had a planned four-week vacation that had been scheduled for July. He was terminated by AM, Inc. in May, and he applied for unemployment compensation benefits shortly thereafter. He had already purchased airline tickets, paid for hotels, and booked various non-refundable reservations for outings during the scheduled vacation. All of the items were purchased in advance and reservations booked would result in no refunds. Since he already saved for the planned vacation, he decided to follow through with it, even though he remained unemployed.
One of Peter's former supervisors, who remained actively employed with AM, Inc., is friends with Peter on Facebook. Peter posted, on Facebook, various photos of his activities during the four-week vacation. In a conversation with the company's human resource manager, the supervisor commented upon Peter's vacation. The human resource manager, in turn, contacted the Department of Employment Security objecting to Peter's eligibility for unemployment compensation benefits during that four-week period of time.
The Department of Employment Security has scheduled a hearing whether to deny Peter benefit coverage for the period in which he was on vacation. Can AM, Inc. protest his continued eligibility benefits, even though it did not originally? Is Peter eligible for benefits during the four-week period? Why, why not? Discuss fully
In: Operations Management
Phil, having exhausted all other appeals in his complaint, called Beth, the compliance officer, to speak with her about a decision that the human resources department had made that he believed was out of compliance with the Federal Equal Pay Act. The office assistant, Mary, stated, “Beth will not be in the office until next week.” Phil then scheduled a telephone conference with Beth for the following week. He asked Mary, “Will my telephone conference with Beth remain confidential?” Mary said, “Most certainly. Our office is here for you. Everything in our office is confidential.”The following week Phil called Beth to discuss his concern that certain professionals were performing the same work as he was and were getting paid more. He described the specifics of his concern. Beth asked, “Is it OK for me to reveal your name to human resources so I can obtain the necessary records that I would need from them to see if you are being paid equally to others for the same work?” Phil agreed to Beth’s request. During his discussion with Beth, Phil discussed several other corporate leadership concerns with her and asked that his conversations remain confidential. Beth replied, “If you wanted confidentiality, then you should have asked for it before speaking to me.” Phil replied, “Confidentiality was promised prior to our discussion and I am surprised at your response.” Beth replied, “Well, you are wrong.”
What lessons could employees learn from Phil’s experience? 2. Discuss how this scenario could have ended with a win-win conclusion for both the employee and the compliance office
In: Operations Management
PLEASE CODE IN JAVA
In this assignment you will write a program in that can figure out a number chosen by a human user. The human user will think of a number between 1 and 100. The program will make guesses and the user will tell the program to guess higher or lower.
Requirements
The purpose of the assignment is to practice writing functions. Although it would be possible to write the entire program in the main function, your solution should be heavily structured. The main function must look like this:
public static void main(String[] args) {
do {
playOneGame();
} while (shouldPlayAgain());
}
The playOneGame function should have a return type of void. It should implement a complete guessing game on the range of 1 to 100.
The shouldPlayAgain function should have a boolean return type. It should prompt the user to determine if the user wants to play again, read in a character, then return true if the character is a ‘y’, and otherwise return false.
In addition, you should implement the helper functions getUserResponseToGuess, and getMidpoint. They should be invoked inside your playOneGame function.
getUserResponseToGuess. This function should prompt the user with the phrase “is it <guess>? (h/l/c): “ with the value replacing the token <guess>. It should return a char. The char should be one of three possible values: ‘h’, ‘l’, or ‘c’. It should have the following signature:
public static char getUserResponseToGuess(int guess)
getMidpoint. This function should accept two integers, and it should return the midpoint of the two integers. If there are two values in the middle of the range then you should consistently chose the smaller of the two. It should have the following signature:
public static int getMidpoint(int low, int high)
In: Computer Science
Please write down your response after reading the paragraphs. (At least 5 sentences long, 150-200 words.)
In a situation where a driverless car is out of control and I am faced with killing myself or five pedestrians, I would sacrifice myself. When purchasing the vehicle, drivers are aware of the risks that come with it as machines are never 100% safe. Although driverless cars were manufactured with the intention of lowering the number of accidents on the road, this does not guarantee that the machine will not malfunction. Those who purchase these vehicles agree to the possibility of the vehicle going out of control and possibly killing themselves in the process. Knowing this, in the case that the machine experiences mechanical failure, the driver who purchased the vehicle should sacrifice themselves in the situation rather than sacrificing the life of five innocent people who did not agree to the terms of trusting their life with a machine.
When society mixes driverless cars with human-driven cars, there is the consequence of humans losing the ability to make decisions. Instead of the driver making the decision of who to kill in the situation, the car makes the decision instead. Not only that, the situation then becomes black and white with only two possible options, killing the driver or the 5 pedestrians as machines are only programmed to think a certain way. Human minds on the other hand, are more flexible and able to think in a different direction. They are able to make the decision of veering in a different direction or finding an option that amounts to the least detrimental effects on everyone in the situation. Rather than relying on machines and being restricted to a selected amount of options in an emergency situation, humans should drive themselves and make their own decisions.
In: Psychology
Please answer the question after reading the short paragraph.
The Department of Transport estimated that last year 35,000 people died from traffic crashes in the US alone. Worldwide, 1.2 million people die every year in traffic accidents. If there was a way we could eliminate 90 percent of those accidents, would you support it? Of course you would. This is what driverless car technology promises to achieveby eliminating the main source of accidents -- human error. Now picture yourself in a driverless car in the year 2030, all of a sudden, the car experiences mechanical failure and is unable to stop. If the car continues, it will crash into a bunch of pedestrians crossing the street, but the car may swerve, hitting one bystander, killing them to save the pedestrians. What should the car do, and who should decide? What if instead the car could swerve into a wall, crashing and killing you, the passenger, in order to save those pedestrians? This scenario is inspired by the trolley problem, which was invented by philosophers a few decades ago to think about ethics.
Question: Should your driverless car kill you if it means saving five pedestrians? In this primer on the social dilemmas of driverless cars, Iyad Rahwan explores how the technology will challenge our morality and explains his work collecting data from real people on the ethical trade-offs we're willing (and not willing) to make. What are the possible outcomes of a society where these kind of vehicles are mixed into human driven cars? Think about the ethical issues when responding. (At least two paragraphs, a paragraph is at least 5 sentences long.)
In: Psychology
In January 2012, Geoff Colvin, a longtime editor at Fortune magazine and a respected commentator on economics and infotech, agreed to play a special game of Jeopardy. The occasion was the annual convention of the National Retail Federation in New York, and Colvin's opponents were a woman named Vicki and an empty podium with the name tag "Watson." Watson's sponsors at IBM wanted to show retailers how smart Watson is. "I wasn't expecting this to go well," recalls Colvin, who knew that Watson had already defeated Jeopardy's two greatest champions. As it turned out, it was even worse than he had expected. "I don't remember the score," says Colvin, "but at the end of our one round I had been shellacked."'
Obviously, Watson isn't your average Jeopardy savant. It's a cognitive computing system that can handle complex problems in which there is ambiguity and uncertainty and draw inferences from data in a way that mimics the human brain. In short, it can deal with the kinds of problems faced by real people. Watson, explains Colvin, "is not connected to the Internet. It's a freestanding machine just like me, relying only on what it knows.... So let's confront reality: Watson is smarter than I am."
Watson is also smarter than anyone who's ever been on Jeopardy, but it's not going to replace human game show contestants any time soon. Watson, however, has quite an impressive skill set beyond its game-playing prowess. For example, it has a lot to offer medical science. At the University of Texas, Watson is employed by the M.D. Anderson Cancer Center's "Moon Shots" program, whose stated goal is the elimination of cancer. This version of Watson, says John Kelly, who oversees the development of IBM's micro-electronics technologies, including Watson, is already "dramatically faster" than the one that was introduced on Jeopardy back in February 2011 (about three times as fast).
Already, reports Kelly, "Watson has ingested a large portion of the world's medical information," and its currently "in the final stages of learning the details of cancer." Then what? "Then Watson has to be trained," explains Kelly. Here's how it works:
Watson is presented with complex healthcare problems where the treatment and outcome are known. So you literally have Watson try to the best diagnosis or therapy and then you look to see whether that was the proper outcome. You do this several times, and the learning engines in Watson begin to make connections between pieces of information. The system learns patterns, it learns outcomes, it learns what sources to trust (emphasis added).
Working with Watson, doctors at the Anderson Center, who are
especially interested in leukemia, have made significant headway in
their efforts to understand and treat the disease. Watson's role in
this process has been twofold:
1. Expanding capacity: It helps to make sense out of so-called big data—the mountain of text, images, and statistics which, according to Kelly, "is so large that traditional databases and query systems can't deal with it." Moreover, says Kelley. big data is "unstructured" and flows "at incredible speeds.... With big data. we're not always looking for precise answers; we're looking for information that will help us make decisions."
2 Increasing speed: Kelley also points out that "Watson can do in seconds what would take people years." The system can, for example, process 500 GB of information—the equivalent of a million books—per second. When it comes to making sense out of the enormous amount of data concerning the genetic factors in cancer, says Kelly; "Watson is like big data on steroids."
Clearly, however, Watson is not replacing "knowledge workers" (doctors) at the Anderson Center. Rather, its being used to facilitate their knowledge work. In this respect, argues Thomas H. Davenport, a widely recognized specialist in knowledge management, Watson is confirming "one of the great cliches of cognitive business technology—that it should be used not to replace knowledge workers, but rather to augment them." On the one hand, even Davenport admits that some jobs have been lost to cognitive technology. In the field of financial services, for instance, "many lower-level" decision makers—loan and insurance-policy originators, credit-fraud detectors—have been replaced by automated systems. At the same time, however, Davenport observes that "experts" typically retain the jobs that call for "reviewing and refining the rules and algorithms [generated byl automated decision systems."
Likewise, human data analysts can create only a few statistical models per week, while machines can churn out a couple of thousand. Even so, observes Davenport, "there are still hundreds of thousands of jobs open for quantitative analysts and big data specialists." Why? "Even though machine learning systems can do a lot of the grunt work," suggests Davenport, "data modeling is complex enough that humans still have to train the systems in the first place and check on them occasionally to see if they're making sense?
Colvin, however, isn't sure that these trends will hold true for much longer. Two years after he competed against Watson, Colvin reported that "Watson is (now] 240 percent faster. I am not He adds that by 2034—when Watson will probably bean antiquated curiosity—its successors will be another 32 times more powerful. "For over two centuries," says Colvin, "practically every advance in technology has sparked worries that it would destroy jobs, and it did.... But it also created even more new jobs, and the improved technology made those jobs more productive and higher paying.... Technology has lifted living standards spectacularly."
Today, however, Colvin is among many experts who question the assumption that the newest generations of technologies will conform to the same pattern. "Until a few years ago: acknowledges former Treasury Secretary Larry Summers, "I didn't think (technological job loss) was a very complicated subject. I'm not so completely certain now." Microsoft founder Bill Gates, on the other hand, is not quite so ambivalent: "Twenty years from now," predicts Gates. "labor demand for lots of skill sets will be substantially lower. I don't think people have that in their mental model."
According to Colvin, today's technology already reflects a different pattern in job displacement: It's "advancing steadily into both ends of the spectrum" occupied by knowledge workers, replacing both low-and high-level positions and "threatening workers who thought they didn't have to worry." Take lawyers, for instance. In the legal-discovery process of gathering information for a trial, computers are already performing the document-sortirg process that can otherwise require smai armies of attorneys. They can scan legal literature for precedents much more thoroughly and will soon be able to identify relevant mat-ters of law without human help. Before long, says Colvin, they "will move nearer to the heart of what lawyers do" by offering better advice on such critical decisions as whether to sue or settle or go to trial.
So what appears to be the long-term fate of high-end knowledge workers? Davenport thinks that the picture is "still unclear," but he suggests that, in order to be on the safe side, would-be knowledge workers should consider reversing the cliché about technology as a means of augmenting human activity: "If there is any overall lesson" to be learned from current trends "it is to make sure you are capable of augmenting an automated system. If the decisions and actions that you make at work are remarkably similar to those made by a computer. that computer will probably be taking your paycheck before long."
Questions:
I. These clays. according to more and more experts. "every worker is a knowledge worker? Consider the definition of knowledge workers in the text: "workers whose contributions to an organization are based on what they know." In what sense might just about any employee qualify as a "knowledge worker"? For example, what qualifies as "knowledge" in an organization's operational activities (that is, in the work of creating its products and services)? What's the advantage to an organization of regarding all employees as knowledge workers?
2. Why are computers, especially cognitive computing systems, so effective in assisting the decision-making process? In particular, how can they increase the likelihood of good decisions under conditions of risk and uncertainty?
3. "The overwhelming message," says Geoff Colvin, seems lo be that no one is safe. "Technological unemployment may finally be here. But even if that's true... it will also be true that, as always, technology is making some skills more valuable and others less so.... Which skills will be the winners?" Colvin supplies one at least one answer to his own question: "it just seems common sense that the skills that computers cant acquire—forming emotional bonds, making human judgments—will be valuable." Thomas Davenport agrees: "It's probably not a bad idea," he suggests. "to improve your human-relationship skills."
Think of a few jobs in which the application of "human-relationship skills" is important—even absolutely necessary. Explain why these jobs require more than just decision-making skills. How about you? Does the job that you want require good human-relationship skills? Do your human-relationship skills need sonic improvement? What sorts of things can you do to improve them?
4. Science journalist Patrick J. Eiger reports that students of the future are likely to have it a lot easier because digital textbooks equipped with artificial intelligence capabilities will guide them along with the patience and perceptiveness of their favorite kindly professors. Take the newly developed Inquire intelligent biology textbook for the iPad. It allows students to stop and type in a question like "What does a protein do? and then presents them with a page full of information specific to whatever concept they're stuck on."
Using "What does a protein do as a model, think of three questions that you would like to ask this book about topics in this chapter. Explain why you chose the questions that you did and what sort of information you'd find helpful in response to each of your questions.
In: Operations Management
QUESTION 1
A plant cell in a beaker of pure water will become ___________________.
|
Shriveled (crenated) |
||
|
Turgid |
||
|
Lysed |
||
|
Plasmolyzed |
4 points
QUESTION 2
An animal blood cell in a beaker of high salt water will become ___________________.
|
Plasmolyzed |
||
|
Turgid |
||
|
Shriveled (crenated) |
||
|
Lysed |
4 points
QUESTION 3
Which of the following is not true regarding facilitated diffusion?
|
It releases energy |
||
|
It is a spontaneous process |
||
|
It is an example of passive transport |
||
|
Substances move across a membrane against the concentration gradient |
4 points
QUESTION 4
NAD+ is the ___________ form of the electron carrier, NADH is the ____________________ form. When NADH reaches the electron transport chain, it ____________________ complex one to become NAD+.
|
Reduced oxidized, oxidizes |
||
|
Reduced, oxidized, reduces |
||
|
Oxidized, reduced, oxidizes |
||
|
Oxidized, reduced, reduces |
4 points
QUESTION 5
How many protons are pumped from the electron transport chain for each FADH2 oxidized?
|
6 |
||
|
2 |
||
|
10 |
||
|
4 |
4 points
QUESTION 6
How many protons are pumped from the electron transport chain for each NADH oxidized?
|
2 |
||
|
10 |
||
|
6 |
||
|
4 |
4 points
QUESTION 7
The terminal electron acceptor during aerobic cellular respiration is __________________________.
|
O2 |
||
|
NAD+ |
||
|
Pyruvate |
||
|
H2O |
4 points
QUESTION 8
If a cell has more concentration of solutes inside than outside, it is in a(n) __________ environment.
|
Mesotonic |
||
|
Isotonic |
||
|
Hypertonic |
||
|
Hypotonic |
4 points
QUESTION 9
The terminal electron acceptor during lactic acid fermentation is __________________________. (i.e. where do the electrons end up during lactic acid fermentation).
|
O2 |
||
|
Pyruvate |
||
|
NAD+ |
||
|
H2O |
4 points
QUESTION 10
If a cell has less concentration of solutes inside than outside, it is in a(n) ___________ environment.
|
Hypertonic |
||
|
Isotonic |
||
|
Hypotonic |
||
|
Mesotonic |
4 points
QUESTION 11
If a cell is in a isotonic state (environment), the cell _______________________.
|
Loses water |
||
|
Has no net change in water concentration |
||
|
Converts the water to salt |
||
|
Gains water |
4 points
QUESTION 12
FADH2 is the ___________ form of the electron carrier, FAD is the ____________________ form. When FADH2 reaches the electron transport chain, it ____________________ complex two to become FAD.
|
Oxidized, reduced, reduces |
||
|
Oxidized, reduced, oxidizes |
||
|
Reduced, oxidized, oxidizes |
||
|
Reduced, oxidized, reduces |
4 points
QUESTION 13
If a cell in in a hypotonic state (environment), the cell _______________________.
|
Gains water |
||
|
Has no net change in water |
||
|
Loses water |
||
|
Converts the water into salt |
4 points
QUESTION 14
Which of the following would have the lowest (most negative) standard reduction potential (E’0)?
|
NADH |
||
|
Glucose |
||
|
FADH2 |
||
|
O2 |
4 points
QUESTION 15
Which of the following is not a product of cellular respiration?
|
Glucose |
||
|
H2O |
||
|
CO2 |
||
|
ATP |
4 points
QUESTION 16
The limiting factor that must be replenished during fermentation is __________________________.
|
H2O |
||
|
NAD+ |
||
|
O2 |
||
|
Pyruvate |
4 points
QUESTION 17
How many net ATP are formed during glycolysis?
|
6 |
||
|
4 |
||
|
2 |
||
|
10 |
4 points
QUESTION 18
How many NADH are formed by the Krebs Cycle? (per glucose)
|
4 |
||
|
10 |
||
|
6 |
||
|
2 |
4 points
QUESTION 19
Which of the following is not a part of cellular respiration?
|
Glycolysis |
||
|
Calvin cycle |
||
|
Kreb's cycle |
||
|
Oxidation of pyruvate |
4 points
QUESTION 20
Where is the proton concentration high in the mitochondria?
|
Matrix |
||
|
Intermembrane space |
||
|
Outer membrane |
||
|
Inner membrane |
4 points
QUESTION 21
In the reaction Na + Cl à Na+ + Cl-, which component is said to become ‘oxidized’ and which is considered reduced?
|
Na, Na |
||
|
Cl, Cl |
||
|
Na, Cl |
||
|
Cl, Na |
4 points
QUESTION 22
If a cell is in a hypertonic state (environment), the cell _______________________.
|
Loses water |
||
|
Gains water |
||
|
Converts the water to salt |
||
|
Has no net change in water concentration |
4 points
QUESTION 23
Which of the following can undergo simple diffusion through a phospholipid bilayer?
|
H2O |
||
|
K+ |
||
|
CO2 |
||
|
Glucose |
In: Biology
QUESTION 91
A virulent phage is a bacterial virus that
|
Is also known as temperate phage |
||
|
Causes lysis of the infected bacterial cells immediately upon infection. |
||
|
Has a life cycle during which it can switch from lysogenic to a lytic cycle |
||
|
Has a life cycle with a lysogenic phase during which it remains integrated in the bacterial chromosome for ever. |
||
|
All of the above is true of a virulent phage. |
QUESTION 92
Heritable changes in the nucleotide sequnce of DNA of an organism's genome are
|
mutations |
||
|
epigenetic modifications |
||
|
genomic imprinting |
||
|
hybridizations |
||
|
lytic cycles |
QUESTION 93
In meiosis, bivalents line up on the equatorial plate of the cell during ___________, and sister chromatids separate from one another during_________.
|
prophase II; metaphase I, |
||
|
prophase I; prophase II, |
||
|
metaphase I, anaphase II |
||
|
metaphase II, prophase I |
||
|
metaphase II, metaphase II |
QUESTION 94
Mutated tumor-suppressor genes act in a _________manner, while oncogenes act in a _________ manner to produce the cancer phenotype.
|
Malignant; benign |
||
|
Recessive; dominant |
||
|
Benign; malignant |
||
|
Benign; benevolent |
||
|
Dominant; recessive |
QUESTION 95
How is a mammal cloned from an adult individual?
|
The diploid nucleus of an egg cell is removed and replaced with the haploid nucleus of a donor cell from the adult mammal. |
||
|
A fertilized egg cell is allowed to divide in vitro, and then the resulting early embryo is split into several small clusters of embryonic cells. |
||
|
A haploid egg cell is fertilized with a haploid sperm in vitro. |
||
|
The haploid nucleus of an egg cell is removed and replaced with the diploid nucleus of the donor cell from the adult mammal. |
||
|
It is not possible to clone a mammal: It is all fake news fabricated by the liberal media. |
QUESTION 96
Which of the following is/are the goal(s) of therapeutic cloning?
|
To clone a new organism that is genetically identical to the donor organism. |
||
|
To implant cloned embryos into a female uterus for gestation and delivery of a newborn individual. |
||
|
To replace or repair damaged cells to treat human disease |
||
|
To determine that a naturally conceived fetus in the motherâ s uterus will not be born with trisomy 21 |
||
|
All of the above are goals of therapeutic cloning. |
QUESTION 97
Which modified base of the DNA is associated with epigenetic marks?
|
Formyl-methionine |
||
|
Methyl-cytosine |
||
|
Pseudo-uridine |
||
|
Dihydro-uridine |
||
|
Methyl-inosines |
QUESTION 98
The connection between maternal grooming patterns and anxiety level in adult rats includes:
|
The amount of royal jelly consumed by the father. |
||
|
X chromosome inactivation in the mother |
||
|
X chromosome inactivation in the father |
||
|
Deletion of the SNRPN, Necdin and UBE3A genes, causing Angelman Syndrome |
||
|
Altering the level of expression of the glucocorticoid receptor gene in the hippocampus. |
QUESTION 99
How does histone de-acetylation affect transcription of a gene?
|
It always enhances transcription |
||
|
It always represses transcription |
||
|
It depends on which amino acid of which histone protein is methylated |
||
|
It opens up the chromatin and prevents heterochromatin formation. |
||
|
It does not influence transcription, but leads to the initiation of DNA replication at the gene |
QUESTION 100
What would be the first step in cloning the DNA fragment which contains the promoter and the introns of a gene?
|
To extract mRNA to construct a cDNA library. |
||
|
To extract DNA to construct a genomic library |
||
|
To design a crRNA so that the promoter can be targeted with CRISPR-Cas9 system |
||
|
To design a silencing construct so that the expression from the promoter can be down-regulated using RNAi. |
||
|
To make a cross between an individual which has the promoter in its genome with another individual which does not. |
In: Biology
Background:
A 25-year-old African-American female complaining of tiredness and increased urination presented with swelling of the legs and feet. Her blood pressure at the time of intake was 185/95, indicating hypertension. Her chart indicates she is 5 feet 2 inches tall and weighs 120 pounds.
Clinical Test Results:
Glucose using glucose meter (blood): 120 mg/dL
Glucose test with Benedict’s reagent (urine): acid green
Glucose test using reagent strips (urine): army green / brown
Protein: cloudy white precipitate forms Specific Gravity: 1.002 pH: 6.0
Ions: none
Urine observation: medium yellow Ketones: no precipitate is present
Urobilinogen: no pink color is detected
| CK enzyme | LD enzyme | |||||
| Positive Sample | Patient | Positive Sample | Patient | |||
| time (min) | absorbance | absorbance | time (min) | absorbance | absorbance | |
| 0.5 | 10 | 10 | 0.5 | 20 | 20 | |
| 1 | 30 | 20 | 1 | 50 | 50 | |
| 1.5 | 60 | 40 | 1.5 | 100 | 110 | |
| 2 | 110 | 70 | 2 | 180 | 180 | |
| 2.5 | 160 | 100 | 2.5 | 260 | 250 | |
| 3 | 210 | 130 | 3 | 340 | 320 | |
| 3.5 | 260 | 160 | 3.5 | 420 | 390 | |
| 4 | 310 | 190 | 4 | 500 | 460 | |
| 4.5 | 360 | 220 | 4.5 | 580 | 530 | |
| 5 | 410 | 250 | 5 | 660 | 600 | |
| 5.5 | 460 | 280 | 5.5 | 740 | 670 | |
| 6 | 510 | 310 | 6 | 820 | 740 | |
| 6.5 | 560 | 340 | 6.5 | 900 | 810 | |
| 7 | 610 | 370 | 7 | 980 | 880 | |
| 7.5 | 660 | 400 | 7.5 | 1060 | 950 | |
| 8 | 710 | 430 | 8 | 1140 | 1020 | |
| 8.5 | 760 | 460 | 8.5 | 1220 | 1090 | |
| 9 | 810 | 490 | 9 | 1300 | 1160 | |
| 9.5 | 860 | 520 | 9.5 | 1380 | 1230 | |
| 10 | 910 | 550 | 10 | 1460 | 1300 | |
| 10.5 | 960 | 580 | 10.5 | 1540 | 1370 | |
| 11 | 1010 | 610 | 11 | 1620 | 1440 | |
| 11.5 | 1060 | 640 | 11.5 | 1700 | 1510 | |
| 12 | 1110 | 670 | 12 | 1780 | 1580 | |
| 12.5 | 1130 | 700 | 12.5 | 1810 | 1610 | |
| 13 | 1150 | 720 | 13 | 1840 | 1640 | |
| 13.5 | 1160 | 730 | 13.5 | 1860 | 1660 | |
| 14 | 1170 | 740 | 14 | 1870 | 1670 | |
| 14.5 | 1180 | 750 | 14.5 | 1880 | 1680 | |
| 15 | 1180 | 750 | 15 | 1880 | 1680 | |
A. Based on the table, can you determine the CK and LD (needs to be graphed to determine value). What does the table represent?
B.What tests can be done to determine what is wrong with the patient and an explanation as to why each of the tests completed would be valuable to the diagnostic process.
C.Evaluation of the clinical test results provided for the unknown case study with a detailed explanation of interpreted results.
D.Conclusion regarding the potential disease(s) present in the unknown scenario, the final diagnosis supported with specific clinical test results.
E.Potential treatment plan for the unknown case study patient.
In: Nursing
Complete the project functions for this week. Note that you have two weeks to complete these functions, however you should aim to get most of them done this week so you can focus on your own additions to the project next week. These functions are setup_game(), play_game() and computer_move(). To complete these functions, first remove the library function call from the function in the template (save_game_lib, etc), then replace that with your own code to complete the function. You can test your functions separately from the project by creating a small main() function that calls them (with appropriate inputs), or you can compile the entire project and see if it works.
setup_game(): The setup_game function takes a Game pointer as input, and initialises this structure so that it is ready to play a new game. There are three main tasks that this function needs to achieve. Firstly, it needs to determine whether player 1 and player 2 are human or
computer players. To do this, a prompt should be displayed to the user and they can enter 'h' for human or 'c' for computer for both players. The results of this input should set the "player1" and "player2" fields of the game structure to either 0 for a computer player or 1 for a human player. Next, your function needs to initialise the board to be empty, by filling every square with zeros. Finally, the turn and winner fields of the structure should be set. winner should be set to 0 (since nobody has won yet), and turn should be a randomly chosen as either 1 or 2.
play_game(): This function performs all the actions necessary to play the game. Most of the functionality of the game has already been implemented by other functions, so the main task of the play_game functions is to call these in the correct way. It takes a pointer to a Game as input, and this structure is assumed to be already initialised to either a new game or a game in progress. The function needs to then run the game until either somebody has won, or the board is full (a draw). To do this, on each turn the game needs to display the board, then either (a) get a move from the keyboard for a human player, or (b) determine a computer move for a computer player, then add this move to the board. The turn and winner fields should then be updated to reflect the new state of the game. If a human player enters 's' or 'q' (as indicated by the return value of get_move) then the move isn't added and the turn field is not changed, but instead the game is saved or quit as appropriate. Your play_game function should use the existing functions (get_move, add_move, display_board, board_full, winner, save_game, etc) to perform all the relevant tasks. You can also use the wait_seconds() function to delay the game for a few seconds before the computer moves, in order to stop this happening instantly.
computer_move(): This function is the "artificial intelligence" of the game. It takes the current board array, the player whose turn it is, and the 'level' of the AI as input, and returns a column number (between 1 and COLS) in which the computer will play. This is very similar to the get_move() function, except that rather than asking the player for a move, one is generated by the AI. The 'level' variable determines how 'smart' the AI is. Level 0 should just generate a random column (that isn't full) and return that. Level 1 should look if the computer can win the game in any column, and if so choose that column. If not, a random valid non-full column is chosen. For level 2, the computer should also check if the opponent can win in any column, and choose that column to block them. Level 3 and above do not need to be implemented for this version, so the behaviour should be the same as level 2.
HINT: Create a copy of the board, so that you can 'test' each move in turn (using add_move and winner) to see if it wins, and choose that column if so. If not, you can reset the copy back to the original board and try again.
TEMPLATE FILE:
#include
#include
#include
#include
#include
#include "connect4.h"
int main ( void ){
int option ;
Game g ;
// intitialise random seed
srand(time(NULL));
while (( option = main_menu()) != -1 ){
if ( option == 1 ){
// setup a new game
setup_game ( &g ) ;
// now play this game
play_game ( &g ) ;
} else if ( option == 2 ){
// attempt to load the game from the save file
if ( load_game ( &g, "game.txt" ) == 0 ){
// if the load went well, resume this game
play_game ( &g ) ;
} else {
printf ( "Loading game failed.\n") ;
}
} else if ( option == -1 ){
printf ( "Exiting game, goodbye!\n") ;
}
}
}
// WEEK 4-5 TASKS
// setup_game()
// play_game()
// computer_move()
// calcualtes a column for the computer to move to, using
artificial "intelligence"
// The 'level' argument describes how good the computer is, with
higher numbers indicating better play
// 0 indicates very stupid (random) play, 1 is a bit smarter, 2
smarter still, etc..
int computer_move ( int board[COLS][ROWS], int colour, int level
){
// If level 0, this is a 'dumb' opponent, pick a random column that isn't full and return that
// If level 1, this is slightly smarter - if the computer's move can win the game, choose that column, otherwise random
// If level 2, slightly smarter again. If computer can win it will do that, otherwise it will block an opponent's winning move, otherwise random
// Higher levels are up to you!
// Hint - you can copy the board into a 'temporary' board and
trial putting a token in a column, then simply call the winner
function to see
// if that move has won the game. Doing this for the current player
will check if that player can win, doing it for the opponent will
see if the opponent can win next turn
// You can use "lookahead" logic to search for the 'best' move many moves ahead
return computer_move_lib ( board, colour, level ) ;
}
// sets up the game to a new state
// prompts the user if each player should be a human or computer,
and initialises the relevant fields
// of the game structure accordingly
int setup_game ( Game *g ){
// prompt the user to enter whether each player is a human or
computer (h or c)
// set the player1 and player2 fields of the struct accordingly (1
for human, 0 for computer)
// initialise the board to all zeros
// set winner to 0 ( no winner yet!)
// set turn to either 1 or 2 (randomly)
return setup_game_lib ( g ) ;
}
// Starts or resumes playing the Game g. Continues until the game
is over or the user quits.
int play_game ( Game *g ){
return play_game_lib ( g ) ;
}
#ifndef CONNECT4_H
#define CONNECT4_H 1
#define ROWS 6 // height of the board
#define COLS 7 // width of the board (values of 9 are going to display poorly!!)
// These lines detect what sort of compiler you are using. This is used to handle the time delay
// function wait() in various operating systems. Most OS will use sleep(), however for windows it is
// Sleep() instead.
#ifdef _WIN32
#include <windows.h>
#else
#include <unistd.h>
#endif
typedef struct {
int player1, player2 ; // variables for each player - 1 for human, 0 for computer player
int board[COLS][ROWS] ; // the game board. 0 for empty space, 1 for player 1, 2 for player 2
// Note that row 0 is the TOP row of the board, not the bottom!
// column 0 is on the left of the board
int turn ; // whose turn it is, 1 or 2
int winner ; // who has won - 0 for nobody, 1 for player 1, 2 for player 2
} Game ;
// displays the welcome screen and main menu of the game, and prompts the user to enter an option until
// a valid option is entered.
// Returns 1 for new game, 2 for load game, -1 for quit
int main_menu ( void ) ;
// displays the board to the screen
int display_board ( int[COLS][ROWS] ) ;
// sets up the game to a new state
// prompts the user if each player should be a human or computer, and initialises the relevant fields
// of the game structure accordingly
int setup_game ( Game *g ) ;
// Returns TRUE if the specified column in the board is completely full
// FALSE otherwise
// col should be between 1 and COLS
int column_full ( int[COLS][ROWS], int col ) ;
// plays a game until it is over
int play_game ( Game *g ) ;
// prompts the user to enter a move, and checks that it is valid
// for the supplied board and board size
// Returns the column that the user has entered, once it is valid (1-COLS)
// note that this value is betweeen 1 and COLS (7), NOT between 0 and 6!!
// If the user enters 'S' or 's' the value -1 should be returned, indicating that the game should be saved
// If the user enters 'Q' or 'q' the value -2 should be returned, indicating that the game should be abandoned
int get_move ( int[COLS][ROWS] ) ;
// calcualtes a column for the computer to move to, using artificial "intelligence"
// The 'level' argument describes how good the computer is, with higher numbers indicating better play
// 0 indicates very stupid (random) play, 1 is a bit smarter, 2 smarter still, etc..
int computer_move ( int[COLS][ROWS], int colour, int level ) ;
// adds a token of the given value (1 or 2) to the board at the
// given column (col between 1 and COLS inclusive)
// Returns 0 if successful, -1 otherwise
int add_move ( int b[COLS][ROWS], int col, int colour ) ;
// determines who (if anybody) has won. Returns the player id of the
// winner, otherwise 0
int winner ( int[COLS][ROWS] ) ;
// determines if the board is completely full or not
int board_full ( int[COLS][ROWS] ) ;
// saves the game to the specified file. The file is text, with the following format
// player1 player2 turn winner
// board matrix, each row on a separate line
// Example:
//
//1 0 1 0 player 1 human, player 2 computer, player 1's turn, nobody has won
//0 0 0 0 0 0 0 board state - 1 for player 1's moves, 2 for player 2's moves, 0 for empty squares
//0 0 0 0 0 0 0
//0 0 0 2 0 0 0
//0 0 0 2 0 0 0
//0 2 1 1 1 0 0
//0 2 2 1 1 2 1
int save_game ( Game g, char filename[] ) ;
// loads a saved game into the supplied Game structure. Returns 0 if successfully loaded, -1 otherwise.
int load_game ( Game *g, char filename[] ) ;
// waits for s seconds - platform specific! THIS FUNCTION IS INCLUDED IN THE LIBRARY, NO NEED TO WRITE IT!
void wait_seconds ( int s ) ;
// library versions of functions. Exactly the same behaviour done by course staff. Please just call these if you have not completed your version as yet.
int display_board_lib ( int[COLS][ROWS] ) ;
int setup_game_lib ( Game *g ) ;
int column_full_lib ( int[COLS][ROWS], int col ) ;
int play_game_lib ( Game *g ) ;
int get_move_lib ( int[COLS][ROWS] ) ;
int add_move_lib ( int b[COLS][ROWS], int col, int colour ) ;
int winner_lib ( int[COLS][ROWS] ) ;
int board_full_lib ( int[COLS][ROWS] ) ;
int computer_move_lib ( int[COLS][ROWS], int colour, int level ) ;
int save_game_lib ( Game g, char filename[] ) ;
int load_game_lib ( Game *g, char filename[] ) ;
int main_menu_lib ( void ) ;In: Computer Science