(a) Find a canonical cover for the FDs of the following table. (b) Put the table into 3NF.
T(A, B, C, D, E)
B --> CD
CD --> A
BC --> A
CD --> E
B --> E
In: Computer Science
do the following SQL programming tasks:
In: Computer Science
hi, can you draw me a cloud using turtle from python.
please send me the codes
In: Computer Science
What is the difference between port preservation and port forwarding? Can you explain it in plain language?
Thank you so much.
In: Computer Science
In: Computer Science
2.7 Implement an environment for a nxm rectangular room, where
each square has a 5% chance
of containing dirt, and n and m are chosen at random from the range
8 to 15, inclusive.
2.8 Design and implement a pure reflex agent for the environment of
previous problem 2.7, ignoring
the requirement of returning home, and measure its performance.
Explain why it is impossible
to have a reflex agent that returns homeland shuts itself off.
Speculate on what the best possible
reflex agent could do. What prevents a reflex agent from doing very
well?
2.9 Design and implement several agents with internal state.
Measure their performance. How
close do they come to the ideal agent for this environment?
2.10 Calculate the size of the table for a table-lookup agent in
the domain of problem 2.7 .
Explain your calculation. You need not fill in the entries for the
table.
2.11 Experiment with changing the shape and dirt placement of the
room, and with adding
furniture. Measure your agents in these new environments. Discuss
how their performance
might be improved to handle more complex geographies.
In: Computer Science
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
True/False
In: Computer Science
linux
Now use the date command and use redirection to APPEND today's date to the INSERTHERE file created (you want to append to the end of the file, not overwrite your name). What command did you use to do this?
In: Computer Science
Read the article and answer the question:
Question: Write your position (3 to 4 paragraphs) about Who Controls the Internet based on Dr. Wu
title:Hooking up
Let's say you're an entrepreneur who has an idea to build a wireless fob that finds your keys even if you left them in Virginia or Barcelona. Or say you want to design a refrigerator that transmits a signal to Safeway, instructing it to deliver a gallon of milk every time you're running low. To enter the market you will have to turn to one of the four mobile phone carriers that today exercise an oligopoly over wireless device communications: Verizon Wireless, AT&T, Sprint and T-Mobile.
Good luck. Get ready for an endless set of hurdles, including lengthy trials, revenue sharing and demands to cripple or modify features, without any guarantee of final approval. All that before your fob or fridge can transmit a tiny signal. In practice, many innovative devices never reach the market. The Big Four tend to approve only established partners whose devices fit their business plans, which is why we have yet to see all those wireless devices that were supposed to be in our future.
The firms already control what phones or devices reach Americans; 95% of cell phones are sold by the wireless carriers themselves. They strictly control phone design, blocking features that might threaten their revenue, like timers that keep track of how many minutes you've used each month. The carriers have also crippled or blocked alternative means of connecting wirelessly, like Bluetooth and Wi-Fi, because they want you to burn up minutes on their networks and charge extra fees.
The good news is that the federal government will soon have a chance to change all that and throw open America's airwaves to innovation and entrepreneurship. It will come in the form of an auction, within the next year, of the few remaining pieces of a precious national resource--licenses to the nation's wireless spectrum. This particular chunk of spectrum is becoming available because TV stations must stop using it to broadcast old-fashioned analog television by February 2009.
That's why this year's auction is so important. The Federal Communications Commission will soon deliver an initial set of rules to govern the spectrum auction. What's needed to spur innovation is a simple requirement: that any winner of the auction respect a rule that gives consumers the right to attach any safe device (meaning it does no harm) to the wireless network that uses that spectrum. It's called the Cellular Carterfone rule, after a 1968 decision by the FCC in a case brought by a company called Carter Electronics that wanted to attach a shortwave radio to AT&T 's network. That decision resulted in the creation of the standard phone jack. Applying the Carterfone rule to the next spectrum auction would ensure that our key fob designer need only look up standard technical specifications and then build and sell his device directly to the consumer. The tiny amounts of bandwidth the fob used would show up on the consumer's wireless bill.
The right to attach is a simple concept, and it has worked powerfully in other markets. For example, in the wired telephone world Carterfone rules are what made it possible to market answering machines, fax machines and the modems that sparked the Internet revolution.
Attachment rights can break open markets that might otherwise be controlled by dominant gatekeepers. Longshot companies like Ebay or YouTube might never have been born had they first needed the approval of a risk-averse company like AT&T. If you've invented a new toaster, you don't have to get approval from the electric company. Consumers decide how good your product is, not some gatekeeper.
But who has the political courage to push such ideas? To date, House Representatives Edward Markey (D--Mass.) and John Dingell (D--Mich.) have taken the lead in Congress by holding hearings on the issue. John McCain is the only presidential candidate so far to take a serious interest. Others should take notice. If America's reputation as the world's leading innovator is to be sustained, we need to get wireless policy right.
Tim Wu Professor at Columbia Law School and Author
In: Computer Science
PLEASE WRITE CLEAR AND CONCISE CODE
Subject is Unix system programming
Write code that downloads all of the log files ending in `.log` in an S3 bucket and counts the total number of HTTP errors in those logs.
Log lines are in the format `{"path": "/", status: 200}` or `{"path": "/", status: 404}`, for example. (This is JSON, and you can process it as such if you choose.)
Use the bucket `class6-logs`, the access key ID "AKIASUMBPHIPY6DLZ4C5", and the secret access key "JQdQIbxsRcipnoKFnsfse44SMRGouzz4tbAzTYbe".
Use the code below to get started:
Code-
import boto3
client = boto3.client(
's3',
aws_access_key_id="AKIASUMBPHIPY6DLZ4C5",
aws_secret_access_key="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",
)
resp = client.list_objects(Bucket='class6-logs')
client.download_file('class6-logs', resp['Contents'][0]
['Key'], 'downloaded_file')
# for object in resp['Contents']:
# print(object['Key'])
# print(resp['Contents'][0]['Key'])
In: Computer Science
how to get this to not consider 0, 1 and negative integers as prime. maybe using a "nested loop" or more than one loop?
//TestCode.java import java.util.Scanner; public class TestCode { public static void main(String[] args) { // Creating scanner object Scanner scan = new Scanner(System.in); boolean isPrime; int x; // Declaring an array with 10 ints int arr[] = new int[10]; // Reading values from user System.out.println("Enter 10 integer values for array:"); for(int i = 0;i<arr.length;i++){ arr[i] = scan.nextInt(); } // Looping through each value in array for(int i = 0;i<arr.length;i++){ x = arr[i]; // Assuming x is prime isPrime = true; // Loop through 2 to x-1 for(int j = 2;j<x;j++){ // if x is divisible by any of j if(x%j == 0) { // Then setting isPrime to false isPrime = false; } } // Printing value of x if it is a prime if(isPrime){ System.out.println(x); } } } }
In: Computer Science
Exploring Web-based Programs and Apps
Use Google to find information about web-based programs and apps to answer the following questions:
In: Computer Science
This is in Python, I am trying to create a new window to print the data to screen, it prints fine in the terminal. I know this is a small segment of my code and its the only portion I am having a problem with. I was wondering if anyone can see what my problem may be. The current issue is
NameError: name 'fltVal' is not defined and AttributeError: 'PressureGUI' object has no attribute 'r_count'
Any help would be appreciated Based on the comment I made some changes which got me past the error above
The updated code is now with a new error of
File "/Volumes/NO NAME/CSE-222/Data Analysis
Program/pressure_data.py", line 175, in
print_data_range_console
text= str(format(float,
'10.2f'))).grid(row=self.r_count,column=self.c_count)
TypeError: unsupported format string passed to type.__format__
I know it has to do with line 12 below but I am confused at this point
My output should be barometric pressue in the format of 1028.95 in one column and temp in the second column
def print_data_range_console(self):
new_win = tkinter.Toplevel(self.window)
label = tkinter.Label(new_win, text="Data Print")
#display_data_win = tkinter.Tk
#self.DisplayDataWin = display_data_win()
#self.display_win_open = True
"""Prints the given data selction to the console"""
print(" ".join(self.window.radio_var.get().split()))
for i in self.get_data_range():
self.DisplayWin.dd_win.data_lbl =
tk.Label(self.get_data_range,\
font=('Helvetica',10), bg='white',\
text= str(format(float,
'10.2f'))).grid(row=self.r_count,column=self.c_count)
self.col_count = self.c_count + 1
if self.col_count == 6:
self.col_count = 1
self.row_count = self.r_count + 1
print(" ".join(str(x) for x in i[1:]))
In: Computer Science
CIT 149 JAVA 1 programming question.
The Assignment
This program will display a menu to the user from which they can
choose an option to find the area of a rectangle, the area of a
triangle, or to quit.
The user will make the selection and will be prompted to enter the
height and width, or the base and height, depending upon which
selection they made. The program will then calculate the
appropriate area and display the results.
This program will be in two classes, each in a separate file. One
will contain the main method and the other will contain instance
variables and methods which make up the program.
? Specifications
There are several ways in which this program could be written. However, in order to grade for following specifications and to have a clear path to a solution, it is required that you write your program using the specifications below.
The Instance Variables
Constructing the Methods
Create the following methods:
? All of the methods below will be in the class Area.
menu()
setFirstDimension() (Mutator)
setSecondDimension() (Mutator)
areaOfRectangle()
areaOfTriangle()
displayOutput()
In: Computer Science
Use Google to search for articles discussing the built-in security features of at least two web browsers. Submit your findings in a brief 250 word essay.
In: Computer Science