check the following code:
is the requirements correct ? if not solve it .
All the styles must be in a document style sheet. YOU ARE NOT ALLOWED TO USE THE type ATTRIBUTE ON THE LIST, you must use CSS to apply the style.
<!DOCTYPE html>
<html>
<head>
<title> car list</title>
<style>
body {background-color: powderblue;}
h1 {color: blue;}
p {color: red;}
</style>
</head>
<body>
<style type="text/css"> ol{list-style-type:upper-roman;}
ol ol{list-style-type:upper-alpha;}
ol ol ol{list-style-type:decimal;}
li.compact{background-color:pink;}
li.midsize{background-color:blue;} li.sports{background-
color:red;}
ol.compact{background-color:pink;}
ol.midsize{background-color:blue;}
ol.sports{background-color:red;}
</style>
</head>
<body>
<h1>Nested Ordered List of Cars</h1>
<ol>
<li class="compact">Compact</li>
<ol class="compact">
<li>Two Door</li>
<ol>
<li>2012</li>
<li>Mod2012</li>
<li>REVA</li>
</ol>
<li>Four Door</li>
<ol>
<li>2012</li>
<li>Model 800</li>
<li>Maruthi Swift</li>
</ol>
</ol>
<li class="midsize">Midsize</li>
<ol class="midsize">
<li>Two Door</li>
<ol>
<li>2012</li>
<li>Mod2012</li>
<li>REVA</li>
</ol>
<li>Four Door</li>
<ol>
<li>2012</li>
<li>Model 800</li>
<li>Maruthi Swift</li>
</ol>
</ol>
<li class="sports">Sports</li>
<ol class="sports">
<li>Coupe</li>
<ol>
<li>2012</li>
<li>Mod2012</li>
<li>REVA</li>
</ol>
<li>Convertible</li>
<ol>
<li>2012</li>
<li>Model 800</li>
<li>Maruthi Swift</li>
</ol>
</ol>
</ol>
</body>
</html>
In: Computer Science
How many new processes will be created by each of the following program segment:
a. int i;
for (i = 0; i < 1000; i++)
if (fork()==0) break;
b. int i;
for (i = 0; i < 1000; i++)
if (fork()!=0) break;
c. int i, pid;
for (i = 0; i < 1000; i++)
pid = fork();
In: Computer Science
In: Computer Science
Make this simple C++ code add data into a file called "Medical Database" preferably an excel file.
Also ask the patient for blood type and if they're donors.
Anytime I run this code, it should add new data into the same Medical Database file.
Use comments to explain what each line of code is doing. (including the one I have written)
Side note: I'm trying to explain how data mining works in the medical field and the medical database file is acting a the real database hospitals use for patients.
*Also if can you put a note explaining steps taken to put real data into a real Database. API calling or anything.*
#include<iostream>
#include<string>
using namespace std;
int main() {
string name;
int sytolic,diastolic;
sytolic=diastolic=0;
cout<<"Enter name of Patient: ";
getline(cin,name);
cout<<"Enter "<<name<<"'s sytolic number: ";
cin>>sytolic;
cout<<"Enter "<<name<<"'s diastolic number: ";
cin>>diastolic;
cout<<"Below is "<<name<<"'s blood pressure rating: "<<endl;
cout<<"----------------------------------------------"<<endl;
cout<<"Name of Patient: "<<name<<endl;
cout<<"Blood Pressure Ratings: "<<sytolic<<"/"<<diastolic<<endl;
if(sytolic<120 && diastolic<80)
cout<<"Blood Pressure Category: Normal"<<endl;
if(120<=sytolic && sytolic<=129 && diastolic<80)
cout<<"Blood Pressure Category: Elevated"<<endl;
if((130<=sytolic && sytolic<=139) || (80<=diastolic && diastolic<=89))
cout<<"Blood Pressure Category: HBP - Stage 1"<<endl;
if((140<=sytolic) || (90<=diastolic))
cout<<"Blood Pressure Category: HBP - Stage 2"<<endl;
}
In: Computer Science
2. Assume that you run a website. Your content ranks in position #3 in both organic and paid listings. There are 4,000 clicks every month on this Search Engine Results Page, and your organic and paid listings get a total of 25% of those clicks. If you get three organic clicks for every paid click, how many organic clicks do you receive in a month?
In: Computer Science
2.1) To the HighArray class in the highArray.java program, add a method called getMax() that returns the value of the highest key in the array, or a -1 if the array is empty. Add some code in main() to exercise this method. You can assume all the keys are positive numbers.
2.2) Modify the method in Programming project 2.1 so that the item with the highest key is not only returned by the method but also removed from the array. Call the method removeMax().
// highArray.java
// demonstrates array class with high-level interface
// to run this program: C>java HighArrayApp
////////////////////////////////////////////////////////////////
class HighArray
{
private long[] a; // ref to array a
private int nElems; // number of data items
//-----------------------------------------------------------
public HighArray(int max) // constructor
{
a = new long[max]; // create the array
nElems = 0; // no items yet
}
//-----------------------------------------------------------
public boolean find(long searchKey)
{ // find specified value
int j;
for(j=0; j<nElems; j++) // for each element,
if(a[j] == searchKey) // found item?
break; // exit loop before end
if(j == nElems) // gone to end?
return false; // yes, can't find it
else
return true; // no, found it
} // end find()
//-----------------------------------------------------------
public void insert(long value) // put element into array
{
a[nElems] = value; // insert it
nElems++; // increment size
}
//-----------------------------------------------------------
public boolean delete(long value)
{
int j;
for(j=0; j<nElems; j++) // look for it
if( value == a[j] )
break;
if(j==nElems) // can't find it
return false;
else // found it
{
for(int k=j; k<nElems; k++) // move higher ones down
a[k] = a[k+1];
nElems--; // decrement size
return true;
}
} // end delete()
//-----------------------------------------------------------
public void display() // displays array contents
{
for(int j=0; j<nElems; j++) // for each element,
System.out.print(a[j] + " "); // display it
System.out.println("");
}
//-----------------------------------------------------------
} // end class HighArray
////////////////////////////////////////////////////////////////
class HighArrayApp
{
public static void main(String[] args)
{
int maxSize = 100; // array size
HighArray arr; // reference to array
arr = new HighArray(maxSize); // create the array
arr.insert(77); // insert 10 items
arr.insert(99);
arr.insert(44);
arr.insert(55);
arr.insert(22);
arr.insert(88);
arr.insert(11);
arr.insert(00);
arr.insert(66);
arr.insert(33);
arr.display(); // display items
int searchKey = 35; // search for item
if( arr.find(searchKey) )
System.out.println("Found " + searchKey);
else
System.out.println("Can't find " + searchKey);
arr.delete(00); // delete 3 items
arr.delete(55);
arr.delete(99);
arr.display(); // display items again
} // end main()
} // end class HighArrayApp
In: Computer Science
2. What do the IVK Corporation exhibits (1-1 through 1-6) tell you about the current state of the company? Given this information, what does IVK need from a new management team under CEO Carl William? (this is a reflection question from an adventure of an IT leader book I want the answer to be in Analytical way )
In: Computer Science
Scenario: 1) You are responsible for the design of a new order entry and sales analysis system for a national chain of auto part stores. 2) Each store has a PC that supports office functions. 3) The company also has regional managers who travel from store to store working with the local managers to promote sales. 4) There are four national offices for the regional managers, who each spend about 1 day a week in their office and 4 on the road. 5) Stores place orders to replenish stock daily, based on sales history and inventory levels. 6) The company uses the Internet to connect store PCs into the company’s main computer. 7) Each regional manager has a laptop computer to also connect with stores and the head office. Task: To recommend a technology architecture for supporting the business activities of the company. Should include the following: • Summary of the business and business requirements • Description of the major system’s components/document developments/tasks required during using the SDLC methodology • Identification of challenges and roadblocks that you would anticipate if implementing this project • Definition of how the systems’ analysts (you and your team) will interact with users, management, and other information systems professionals to develop this plan (i.e. questionnaires, interviews, etc.). • Summary of recommendation and justification as the best solution
In: Computer Science
You are creating a system to promote a chain of fancy restaurants around the world. Your system will use an array of dynamically allocated restaurants and should allow adding, removing and modifying restaurants. Your array will contain up to 100 restaurants.
You will create an input .txt file with 20 command of your choice that will include:
Your command list (the input file) should be comprehensive and should contain all relevant scenarios. For example, after you remove one or more restaurants, have a command printing your restaurants to verify that your program works as expected. One of the commands should be QUIT to quit scanning.
You can refer to the assignments of Module 1 for ideas on commands you can use in your input file.
Make sure you deallocate your array before you exit the main() function.
Refer to the rubric to ensure that you have it all covered.
Please use C++ language for this programme.
rubric: 1)input text file Complete, comprehensive and shows all scenarios
2) adding a restaurant Adds a restaurant by searching the first not-null cell in the array and dynamically allocating memory for the new object
3)removing a restaurant Removes a restaurant by searching the restaurant to be removed, deallocating its memory and setting the pointer to null (nullptr)
4) searching The search returns null if the value is not found or the pointer to the restaurant found
5) modifying Searches the restaurant. If found, calls the related setter() to change the value of the restaurant.
6) printing Prints the array in a formatted way
In: Computer Science
Assume that a procedure is formalized as a Turing machine that can be represented as a finite length string from a finite alphabet. Thus any string over this alphabet is a Turing machine. Is the set of all Turing machines countable? Explain. Give an effective enumeration of all Turing machines (that is, show a “procedure” that will list all Turing machines).
In: Computer Science
**PYTHON**
A new movie theatre has three different subscription packages for its customers:
Package A: For $18.95 per month, the customer can watch 2 movies. Any additional movie requires an additional $2 per movie.
Package B: For $22.95 per month, the customer can watch 4 movies. Any additional movie requires an additional $1 per movie.
Package C: For $30.99 per month, the customer can watch an unlimited amount of movie.
Write a script that calculates a customer’s monthly bill. It should ask the user to enter the letter of the package purchased (A, B, or C) and the number of movies watched.
Using that information, your program should display the total bill. Your program should also display an error message and stop if the user enters any invalid values.
Would appreciate any help. Stuck on how to solve this or even get started. Thank you
In: Computer Science
What are today’s primary ways through which machine learning tasks are tackled? Explain the concept of “deep learning” and how it differs from machine learning. How are organizations using deep learning to help make business decisions? Write your responses in detail with EXAMPLES. Be sure to identify the source AND REFERENCES of your example in your posting. Your initial post should be of a minimum of 350;.
In: Computer Science
This is a java assignment Write the body of the fileAverage() method. Have it open the file specified by the parameter, read in all of the floating point numbers in the file and return their average (rounded to 1 decimal place). For the testing system to work, don't change the class name nor the method name. Furthermore, you cannot add "throws IOException" to the fileAverage() header. Additionally, the file will have different contents during testing.
public class Main { public double fileAverage( String filename ){ } public static void main( String[] args ){ Main obj = new Main(); System.out.println( obj.fileAverage( "numbers.txt") ); } }
In: Computer Science
Computing Assignment 1 You must upload both your code (to Assignment 1 scripts/codes) and your report (to Assignment 1 computing report). The assignment is due at 11:00pm. I have set the due time in Canvas to 11:05pm and if Canvas indicates that you submitted late, you will be given 0 on the assignment. Your computing report must be exactly 1 page. There will be a penalty given if your report is longer than one page. • Please read the Guidelines for Assignments first. • Keep in mind that Canvas discussions are open forums. • Acknowledge any collaborations and assistance from colleagues/TAs/instructor. Computing Assignment { Floating Point Arithmetic Required submission: 1 page PDF document and Matlab scripts uploaded to Canvas. 1. Part 1 - warmup Use Matlab and issue the following two commands on the command line: sin(0); sin(π). State your answer and explain the answer you see. This should be done in one or two sentences at the beginning of your report. 2. Part 2 Let 8 ≤ x ≤ 10 be an arbitrary number and n a nonnegative integer. In exact arithmetic, the following computation leaves x unchanged: 1 for i=1:n
2 x=5 log(x);
3 end
4
5 for i=1:n
6 x=exp(x/5.0);
7 end
However, in finite-precision arithmetic the results may be
dramatically different for large n.
The purpose of this assignment is to investigate the output of this
computation in Matlab for
various values of n and for x in the range 8 ≤ x ≤ 10.
Your conclusions should be explained in a one-page report. Your
report must include the
following:
(a) Representative plots of the output as a function of x, with
each plot corresponding to a
different value of n.
(b) A discussion of the smallest value of n after which the result
of the finite-precision
computation begins to differ from exact arithmetic
computation.
1
(c) A discussion of the limiting behaviour for large n.
(d) A brief explanation as to why computing in floating point
arithmetic leads to the results
you have found.
Partial code for this assignment can be found in the file FloatPt.m
on Canvas. I suggest
using this as your starting point. If you have questions about
Matlab or other aspects of
the assignment or course, then I strongly encourage you to attend
the tutorials and drop-in
workshops.
----------------Codes given----------------------
% MACM 316 - Homework 1 % Floating Point Arithmetic with logarithm function % Description: Performs n-fold logarithm followed by n-fold exponentiation % File name: FloatPt_log.m clear %format long; %this changes the number of decimal digits that DISPLAY n=30; st=0.001; % Define a stepsize x=8:st:10; % x is a row vector of numbers between 1.3 and 2.3 of increments st y=x; for i=1:n y=5*log(y); end %y(1) %this is how you print the 1st element of y to the screen %y(11) %y(101) %y(1001) %pause %this stops your program until you press a key for i=1:n y=exp(y/5.0); end %y(1) %y(11) %y(101) %y(1001) % Plot the output y versus the input x plot(x,y) %you can change the title and axis labels in this manner title(['Output of the Computation with n = ' num2str(n)],'fontsize',14) xlabel(['Input x'],'fontsize',12) ylabel(['Output y'],'fontsize',12)
In: Computer Science
Summarize two articles on IT sourcing and compare and contrast the sourcing approaches in each article. Identify the factors that were important in each sourcing strategy and whether the sourcing decision was strategic for the long term or tactical for the short term. Which strategy did you think was more effective and why?
In: Computer Science