Search CSNewbs
286 items found for ""
- 5.2 - Data Flow Diagrams | Unit 2 | OCR Cambridge Technicals | CSNewbs
5.2 - Data Flow Diagrams Exam Board: OCR Specification: 2016 - Unit 2 A data flow diagram is a visual representation of how data is transferred within a system or organisation . Data flow diagrams are often abbreviated to just 'DFD '. You will need to recognise the symbols , understand the diagrams and explain how data flow can be affected . Data Flow Diagram Symbols The common symbols used in a DFD are shown below: External Entity (e.g. Employee, Customer) Alternative DFD symbols you may see on the exam paper (both sets of symbols have been accepted in previous exam papers): Process (e.g. Calculate Pay, Review Application) Data Store (e.g. Staff Database, Customer Database) Data Flow External Entity Process Data Store Level 0 data flow diagrams show the transfer of data in a simple manner . Processes may be generalised and not shown separately , for a more basic overview . Below is an example of a Level 0 DFD to show the process of an employee submitting an application to be promoted : Level 1 data flow diagrams show the transfer of data in a more detailed manner . Processes are shown separately , for a more complex and realistic overview . Below is an example of a Level 1 DFD to show the process of an employee submitting an application to be promoted . The individual processes have been expanded from the Level 0 DFD above to show how the application must first be signed off by an administrator before it is reviewed by management: Rules for Drawing a Level 1 DFD Data flows only in one direction . Every data flow is labelled (with the data itself , not the action). Every data flow connects to at least one process . At least one input or output for each external entity . Impacts Affecting the Flow of Information There are several reasons why the flow of information within an organisation may be delayed or inefficient , such as: Information characteristics e.g. information is entered incorrectly, causing delays. Human error e.g. information is lost or staff don't follow protocol. Hardware failure e.g. network connection breaking or system failure. Communication breakdown e.g. meetings postponed or emails unread. Q uesto's Q uestions 5.2 - Data Flow Diagrams: ​ 1. Draw the symbols for the four parts of a data flow diagram . [4 ] ​ 2. Look at the image of the Level 1 DFD . State one example of: An external entity A process A data flow A data store [1 each ] ​ 3. Give one difference between a Level 0 and Level 1 DFD . [2 ] ​ 4. State three rules for drawing a correct data flow diagram . [3 ] ​ 5. After heavy snow, a school has decided to shut for the next two days. Many parents were not informed of this decision and are angry that they brought their children in. Give three reasons why the transfer of data (the data being a message about school closure) might not have flowed efficiently in this example. [6 ] 1 Level 0 Data Flow Diagram Level 1 Data Flow Diagram 5.1 - Data Types & Sources Topic List 6.1 - Security Principles
- 3.9 - Protection Against Threats - GCSE (2020 Spec) | CSNewbs
3.9: Protection Against Threats Exam Board: Eduqas / WJEC Specification: 2020 + Network Forensics & Penetration Testing What is network forensics? Network forensics is the monitoring of a network to identify unauthorised intrusions . Network forensics is used to record and analyse attacks on a network and to gather other information about how the network is performing. ​ It is important for organisations to identify weaknesses in their networks so that they can fix them and be prepared for any type of attack or malware. ​ Footprinting - Footprinting is one method of evaluating a network’s security . This is when a security team puts itself in the attacker’s shoes by obtaining all publicly available information about the organisation and its network . Footprinting allows the company to discover how much detail a potential attacker could find out about a system. The company can then limit the technical information about its systems that is publicly available . Penetration Tests Penetration tests are carried out as part of ethical hacking. Ethical hacking is when an organisation gives permission to specific 'good ' hackers to try and attack a system so that the weak points can be highlighted and then fixed. The purpose of a penetration test is to review the system's security to find any risks or weaknesses and to fix them . ​ There are four main types of penetration tests : Internal tests are to see how much damage could be done by somebody within the company with a registered account. External tests are for white hat hackers to try and infiltrate a system from outside the company . Blind tests are done with no inside information , to simulate what a real attacker would have to do to infiltrate the system. + Targeted tests are conducted by the company's IT department and the penetration team cooperating together to find faults in the system. Anti-Malware & Firewalls Anti-Malware Software Anti-malware software is used to locate and delete malware, like viruses, on a computer system. The software scans each file on the computer and compares it against a database of known malware . Files with similar features to malware in the database are identified and deleted . There are thousands of known malware, but new forms are created each day by attackers, so anti-malware software must be regularly updated to keep systems secure. Other roles of anti-malware software: Checking all incoming and outgoing emails and their attachments . Checking files as they are downloaded . Scanning the hard drive for viruses and deleting them . Firewall A firewall manages incoming and outgoing network traffic . Each data packet is processed to check whether it should be given access to the network by examining the source and destination address . ​ Unexpected data packets will be filtered out and not accepted to the network. Other roles of a firewall include: Blocking access to insecure / malicious web sites . Blocking certain programs from accessing the internet . Blocking unexpected / unauthorised downloads . Preventing specific users on a network accessing certain files . Other Methods of Protection Double Authentication Also known as two-factor authentication (2FA ), this is a method of confirming someone's identity by requiring two forms of authorisation , such as a password and a pin code sent to a mobile. 4392 Secure Passwords Usernames must be matched with a secure password to minimise the chances of unauthorised users accessing a system. ​ Passwords should contain a mix of uppercase and lowercase letters , punctuation and numbers . Passwords should be of a substantial length (at least 8 characters) and should be regularly changed . ******** User Access Levels Access levels are used to only allow certain users to access and edit particular files. ' Read-Only ' access is when a user can only view a file and is not allowed to change any data . ​ For example, a teacher might set homework instructions as read-only for students to view. ' Read and Write ' access allows a user to read and edit the data in a file. ​ For example, a teacher might set an online workbook as read and write access for students to fill in. It is important to set access levels so that only authorised users can view and change data. The more users who have access to a file, the more likely it is to be compromised. Certain users may also have no access to a file - when they can't view or edit it. Encryption Encryption is the process of scrambling data into an unreadable format so that attackers cannot understand it if intercepted during transmission. ​ The original data (known as plaintext ) is converted to scrambled ciphertext using an encryption key . Only at the correct destination will the encryption key be used to convert the ciphertext back into plaintext to be understood by the receiving computer. ​ A very simple method of encryption is to use the XOR logical operator . XOR is used on the plaintext and key together to create the ciphertext . Using XOR again on the ciphertext and key will reverse the encryption to reveal the plaintext . Encryption using XOR Plaintext = 00110100 Key = 10100110 XOR Ciphertext = 10010010 Decryption using XOR ​ Ciphertext = 10010010 / Key = 10100110 XOR Plaintext = 00110100 Q uesto's Q uestions 3.9 - Protection Against Threats: ​ 1a. What is network forensics ? Why is it important ? [ 3 ] 1b. Explain what is meant by footprinting and why companies do it . [ 2 ] 2. What is an ethical hacker ? [2 ] 3a. Describe the purpose of penetration tests . [2 ] 3b. Describe each type of penetration test . [ 8 ] ​ 4. Describe the purpose of anti-malware software and its different roles . [ 4 ] 5. Describe the purpose of a firewall and its different roles . [ 4 ] ​ 6a. Describe double authentication . [2 ] 6b. State three rules for choosing a strong password . [ 3 ] 7. Describe the three types of access level . [6 ] 8a. Describe the purpose of encryption . [ 2 ] 8b. Explain how encryption works, using the terms plaintext , key and ciphertext . [ 4 ] 3.8 - Cyber Threats Theory Topics 4.1 - Number Systems
- 3.6 - Information Systems | Unit 2 | OCR Cambridge Technicals | CSNewbs
3.6 - Information Systems Exam Board: OCR Specification: 2016 - Unit 2 Information systems, such as structured databases , can be defined primarily as either 'open ' or 'closed '. Open Information Systems Closed Information Systems ​ This type of system can interact with other information systems (e.g. another database) to exchange data , even from different platforms (types of computers).​ ​ Because it is open it is more at risk of data loss and/or hacking. ​ This type of system is private and cannot exchange data with other systems. ​​ Access is limited but it is much more secure than an open system. Q uesto's Q uestions 3.6 - Information Systems: ​ 1. Compare and contrast open and closed information systems . [4 ] 3.5 - Data Analysis Tools Topic List 4.1 - UK Legislation
- Python | 8a - Using Lists | CSNewbs
top Python 8a - Using Lists Lists A list is a temporary data structure . Any changes made to the list while the program is running will not be saved the next time it is run . Data can be added to and removed from lists so they can change in size (unlike an array which is fixed and not used in Python). ​ It is important to note that each data element in a list has an index so that it can be specifically referenced (to delete it for example) and that indexes start at 0 . A list of the rainbow colours in order would start at 0 like this: Creating & Printing Lists Lists use square brackets in Python. Separate list items with commas . Strings must use speech marks and integers do not use speech marks. people = [ "Alan" , "Jesse" , "Max" , "Jack" ] years = [ 2010, 2019, 2001, 2016 ] There are many different ways to print items from a list depending on how you want it to look . Print all items on one line Type the list name into a print command to output the complete list . Typing an asterisk * before the list name removes punctuation . cities = [ "Shanghai" , "Sao Paolo" , "Bishkek" , "Asmara" ] print (cities) cities = [ "Shanghai" , "Sao Paolo" , "Bishkek" , "Asmara" ] print (*cities) ['Shanghai', 'Sao Paolo', 'Bishkek', 'Asmara'] Shanghai Sao Paolo Bishkek Asmara Print each item on a separate line To print a list line-by-line use a for loop to cycle through each item. ​ 'city ' is just a variable name and can be replaced with the traditional 'i ' or anything relevant to the context, such as 'colour ' in a list of colours or 'name ' in a list of people. cities = [ "Shanghai" , "Sao Paolo" , "Bishkek" , "Asmara" ] for city in cities: print (city) Shanghai Sao Paolo Bishkek Asmara Print separated items on one line To print separated data elements on the same line then you can use the end command which defines what should go after each item . ​ The example below uses slashes but end = " , " would add comma and space between each element. cities = [ "Shanghai" , "Sao Paolo" , "Bishkek" , "Asmara" ] for city in cities: print (city, end = " / " ) Shanghai / Sao Paolo / Bishkek / Asmara / Print specific list items To print an element with a certain index , put the index in square brackets . But remember that the index starts at 0 not 1. cities = [ "Shanghai" , "Sao Paolo" , "Bishkek" , "Asmara" ] for city in cities: print ( "The first city is" , cities[0]) print (cities[2], "is the third city" ) The first city is Shanghai Bishkek is the third city Create a list of five different of foods . ​ Print all list items on one line . ​ Then print each item on a different line . ​ Finally print just the first and fifth items . Example solution: lettuce yoghurt tomato artichoke tuna lettuce yoghurt tomato artichoke tuna The first item is lettuce The fifth item is tuna Lists Task 1 (Five Foods ) Lists Task 2 (Four Numbers ) Create a list of four integer values . ​ ​ Print all list items on one line separated by colons . Example solutions: 345:123:932:758: 812:153:783:603: Add (Append / Insert) to a List Append items to the end of a list To add a new item to the end of a list use the .append() command. ​ ​ Write .append() after the name of your list, with the new data in brackets . pets = [ "dog" , "cat" , "hamster" ] pets.append( "rabbit" ) print (*pets) fillings = [ "ham" , "cheese" , "onion" ] extra = input ( "Enter another filling: " ) fillings.append(extra) print ( "Your sandwich:" , *fillings) dog cat hamster rabbit Enter another filling: lettuce Your sandwich: ham cheese onion lettuce Insert items to a specific index Use the insert command to place an item in a specific position within the list. Remember that Python counts from 0 so the medals example below puts "silver" as index 2 , which is actually the 3rd item . medals = [ "platinum" , "gold" , "bronze" ] medals.insert(2, "silver" ) print (*medals) names = [ "Stacy" , "Charli" , "Jasper" , "Tom" ] name = input ( "Enter a name: " ) position = int ( input ( "Enter an index: " )) names.insert(position,name) print (*names) platinum gold silver bronze Enter a name: Lena Enter an index: 0 Lena Stacy Charli Jasper Tom Enter a name: Pat Enter an index: 3 Stacy Charli Jasper Pat Tom Use a loop to add items to a list A for loop can be used to add a certain number of items to a list. A while loop can be used to keep adding values until a certain value (e.g. ' stop ' or ' end ') is input. animals = [ ] ​ for i in range (4): animal = input ( "Enter an animal: " ) animals.append(animal) ​ print ( "\nAnimals:" , *animals) animals = [ ] while True : animal = input ( "Enter an animal: " ) if animal == "stop" : break else : animals.append(animal) print ( "\nAnimals:" , *animals) Enter an animal: lion Enter an animal: horse Enter an animal: hyena Enter an animal: squirrel ​ Animals: lion horse hyena squirrel Enter an animal: rhino Enter an animal: gazelle Enter an animal: deer Enter an animal: stop ​ Animals: rhino gazelle deer Example solution: Lists Task 3 (Favourite Musicicans ) Create a list of three musicians or bands you like . ​ ​ Print the list . ​ ​ ​ Then append two new bands using two inputs . ​ ​ ​ Print the list again. ​ Use the sandwich filling example for help. Musicians I like: Lana Del Rey Devon Cole Elly Duhé ​ Enter another musician: Charli XCX Enter another musician: Kenya Grace ​ Musicians I like: Lana Del Rey Devon Cole Elly Duhé Charli XCX Kenya Grace Lists Task 4 (Missing 7 ) Create a list of numbers in order from 1 to 10 but miss out 7 . ​ Use the insert command to add 7 in the correct place . ​ Print the list before and after you insert 7. Example solution: 1 2 3 4 5 6 8 9 10 1 2 3 4 5 6 7 8 9 10 Lists Task 5 ('Land' Countries ) Use a while True loop to input countries that end in 'land' until the word 'finish ' is input . ​ Print the list at the end. ​ Note: You do not need to check if the countries entered are correct. There are also more than four. Example solution: Enter a country ending in 'land': Iceland Enter a country ending in 'land': Poland Enter a country ending in 'land': Switzerland Enter a country ending in 'land': Thailand Enter a country ending in 'land': finish ​ Country list: Iceland Poland Switzerland Thailand Delete (Remove/Pop) from a List Delete items with a specific value To delete data with a certain value use the .remove() command, with the value in brackets . trees = [ "fir" , "elm" , "oak" , "yew" ] trees.remove( "elm" ) print (*trees) fir oak yew trees = [ "fir" , "elm" , "oak" , "yew" ] tree = input ( "Select a tree to remove: " ) trees.remove(tree) print (*trees) Select a tree to remove: oak fir elm yew Delete items with a specific index To delete data in a specific position in your list use the .pop() command, with the position in the brackets . ​ Remember that indexes start at 0 so .pop(0) removes the first item . Negative values start from the end of the list , so -1 is the final item and -2 is the second last item and so on. kitchen = [ "plate" , "cup" , "spoon" , "jug" ] kitchen.pop(0) print (*kitchen) kitchen = [ "plate" , "cup" , "spoon" , "jug" ] kitchen.pop(-2) print (*kitchen) kitchen = [ "plate" , "cup" , "spoon" , "jug" ] index = int ( input ( "Select an index: " )) kitchen.pop(index) print (*kitchen) cup spoon jug plate cup jug Select an index: 1 plate spoon jug Delete all items in a list To delete data in a list use the .clear() command. insects = [ "ant" , "bee" , "wasp" ] insects.clear() insects.append( "hornet" ) print (*insects) hornet Lists Task 6 (Day Off ) Example solution: Create a list with the five week days . ​ Ask the user to input a weekday and remove that day from the list. ​ Print the list. Which day do you want off? Tuesday Your new days of work: Monday Wednesday Thursday Friday Lists Task 7 (May and October ) Create a list with the twelve months in order . ​ ​ Delete May and then October using the pop command by referring to their indexes in the list. Print the list. ​ Note: Be aware the index of each month after May will change when May is popped from the list. Example solution: January February March April June July August September November December Finding the Length of a List To find the length of a list use the len function. You can create a separate variable for the length (shown in the first example below) or use the len command directly (second example). states = [ "Maine" , "Utah" , "Ohio" , "Iowa" ] length = len (states) print ( "There are" , length , "states in the list." ) states = [ "Maine" , "Utah" , "Ohio" , "Iowa" ] print ( "There are" , len (states), "states in the list." ) There are 4 states in the list. Lists Task 8 (Q Words ) Use a while True loop to input words beginning with q until the word ' stop ' is entered. ​ Then use len to find the length of the list and print this value. ​ Note: You do not need to check if the entered words actually start with q. Example solution: Input a Q word: question Input a Q word: quick Input a Q word: quiet Input a Q word: quandry Input a Q word: stop ​ You wrote 4 Q words! Cycle Through List Items A for loop can be used to cycle through each item in a list. The following examples present some ways that this may be used. ​ ​ This program uses a for loop to add a word (David) before each list item. davids = [ "Beckham" , "Attenborough" , "Schwimmer" , "Tennant" , "Lynch" ] for i in range (5): print ( "David" , davids[i]) David Beckham David Attenborough David Schwimmer David Tennant David Lynch An if statement can be used within a for loop to check the value of each item . The example below checks how many items are 'medium'. sizes = [ "small" , "medium" , "small" , "large" , "medium" , "small" ] count = 0 ​ for i in range (6): if sizes[i] == "medium" : count = count + 1 print ( "There were" ,count, "medium choices." ) There were 2 medium choices. The program below uses a while loop to allow entries until 'stop ' is input then a for loop to check the value of each item . ​ Because the final length of the list is not known when the program starts, the len command is used in the range of the for loop . sports = [] fcount = 0 rcount = 0 ​ while True : option = input ( "Choose football or rugby: " ) sports.append(option) if option == "stop" : break for i in range ( len (sports)): if sports[i] == "football" : fcount = fcount + 1 elif sports[i] == "rugby" : rcount = rcount + 1 ​ print ( "\nResults:" ,fcount, "people chose football and" ,rcount, "chose rugby." ) Choose football or rugby: rugby Choose football or rugby: rugby Choose football or rugby: football Choose football or rugby: rugby Choose football or rugby: football Choose football or rugby: stop ​ Results: 2 people chose football and 3 chose rugby. Lists Task 9 (Over 25 ) Create a list with the following eight numbers: 13, 90, 23, 43, 55, 21, 78, 33 ​ Use a for loop to cycle through the list and check if each item is over 25 . Use a count variable to increase by 1 if the number is over 25. ​ At the end print how many numbers are over 25 - there are five . Example solution: 5 numbers are over 25. Lists Task 10 (Favourite Lesson ) Use a while True loop to keep inputting school subjects until ' done ' is entered. ​ Keep a count of how many times ' Maths ' is entered. ​ Print the total number of people who entered maths. Example solution: Enter a subject: English Enter a subject: Maths Enter a subject: Art Enter a subject: Maths Enter a subject: History Enter a subject: done ​ There were 2 people who chose maths. Sorting Lists The .sort() command will sort elements in a list into alphabetical order (if a string ) or numerical order (if a number ). names = [ "Robb" , "Jon" , "Sansa" , "Arya" , "Bran" , "Rickon" ] print ( "Original:" , *names) ​ names.sort() print ( "Sorted:" , *names) Original: Robb Jon Sansa Arya Bran Rickon Sorted: Arya Bran Jon Rickon Robb Sansa numbers = [56,98,23,12,45] numbers.sort() print (*numbers) 12 23 45 56 98 The .sort() command can be used to sort values in descending order by including reverse = True in the brackets. names = [ "Robb" , "Jon" , "Sansa" , "Arya" , "Bran" , "Rickon" ] print ( "Original:" , *names) ​ names.sort(reverse = True ) print ( "Sorted:" , *names) Original: Robb Jon Sansa Arya Bran Rickon Sorted: Sansa Robb Rickon Jon Bran Arya numbers = [56,98,23,12,45] numbers.sort(reverse = True ) print (*numbers) 98 56 45 23 12 Lists Task 11 (Sorted Fruit ) Example solution: Use a for loop to append six fruits to an empty list. ​ Sort the list into alphabetical order and print it. Enter a fruit: strawberry Enter a fruit: kiwi Enter a fruit: lemon Enter a fruit: pear Enter a fruit: orange Enter a fruit: mango Sorted fruit: kiwi lemon mango orange pear strawberry Searching Through Lists A simple if statement can be used to see if a certain value appears within a list. names = [ "Alex" , "Bill" , "Charlie" , "Darla" ] ​ name = input ( "Enter a name: " ) if name in names: print ( "Yes," , name , "is in the list." ) else : print ( "Sorry," , name , "is not in the list." ) Enter a name: Bill Yes, Bill is in the list. Enter a name: Sadie Sorry, Sadie is not in the list. Lists Task 12 (Packed Suitcase ) Example solutions: Create a list with five items to take on holiday. ​ Ask the user to input an item and use an if statement to check if it is or isn't in the list. What should I pack? sun cream I've already packed sun cream What should I pack? toothpaste Whoops! I forgot to pack toothpaste Calculating the Sum of a List To calculate the sum of a list of numbers there are two methods. Using Python's built-in sum function : numbers = [1,4,2,3,4,5] print ( sum (numbers)) Both methods will result in the same output : 19 Using a for loop to cycle through each number in the list and add it to a total . numbers = [1,4,2,3,4,5] ​ total = 0 for number in numbers: total = total + number print (total) Lists Task 13 (Sum and Average ) Example solution: Use a for loop to ask the user to input 5 numbers and append each to a list. ​ Use the sum command to output the total and use it calculate the average . Enter a number: 6 Enter a number : 7 Enter a number : 6 Enter a number : 9 Enter a number : 4 The total is 32 The average is 6.4 Extending a List .extend() can be used in a similar way to .append() that adds iterable items to the end of a list . ​ This commands works well with the choice command (imported from the random library ) to create a list of characters that can be randomly selected. ​ The code below adds a lowercase alphabet to an empty list and then, depending on the choice of the user, adds an uppercase alphabet too. The choice command is used in a loop to randomly select 5 characters. Using .extend() to make a random 5-character code from random import choice list = [] list. extend ( "abcdefghijklmnopqrstuvwxyz" ) ​ upper = input ( "Include uppercase letters? " ) if upper == "yes" : list. extend ( "ABCDEFGHIJKLMNOPQRSTUVWXYZ" ) ​ code = "" for number in range (5): letter = choice (list) code = code + letter print ( "Your five character code is" , code) Possible outputs: Include uppercase letters? yes Your five character code is yPfRe Include uppercase letters? yes Your five character code is GJuQw = Include uppercase letters? no Your five character code is gberv Extend treats each character as an indidual item whereas append adds the whole string as a single entity . ​ Most of time append would be used, but extend is suitable for a password program as additional individual characters can be added to a list depending on the parameters (e.g. lowercase letters, uppercase letters, numbers and special characters). list = [] list. extend ( "ABCD" ) list. extend ("EFGH" ) print (list) list = [] list. append ( "ABCD" ) list. append ("EFGH" ) print (list) ['A','B','C','D','E','F','G','H'] ['ABCD' , 'EFGH'] = = Practice Task 14 Use the code above (for a 5-character code ) to help you make a password generator . ​ Ask the user if they want uppercase letters , numbers and special characters and use the extend command to add them to a list of characters if they type yes (you should extend lowercase characters into an empty list regardless, like in the code above). ​ Use a for loop and the choice command (imported from the random library) to randomly generate a 10-character password . Example solutions: Include uppercase letters? yes Include numbers? yes Include special characters? yes Your new password is RjWSbT&gW5 Include uppercase letters? no Include numbers? yes Include special characters? no Your new password is hdf8se9y2w ⬅ Section 7 Practice Tasks 8b - 2D Lists ➡
- HTML Guide 7 - Head Tags | CSNewbs
7. Head Tags HTML Guide Watch on YouTube: Remember that all HMTL documents are split into the head and the body. ​ The following tags must be typed inside of your head tags . title Title The title is not the main heading. ​ The title is the page title itself that you can see at the tab at the top of your web browser. Add a title to your web page. metadata Metadata Metadata is information about the web page itself. ​ This commonly includes data about the author, the page's contents and any keywords. ​ Metadata will not appear on the actual web page . Add meta data tags between your head tags for author, keywords and a description. The meta tag is made up of a name and content . ​ Author represents who created the web page. Keywords are commonly used words. Description is used for displaying search engine results (such as a Google search). Next it is time to embed YouTube videos into your web page. 6. Organisation Tags HTML Guide 8. Videos
- OCR CTech IT | Unit 1 | 3.3 - Network Characteristics | CSNewbs
3.3 - Network Characteristics Exam Board: OCR Specification: 2016 - Unit 1 Network Topologies Network topology refers to the arrangement of computer systems on a network . Devices in a network topology diagram are often called 'nodes' . Client-Server Network Clients make requests to a server , the server manages that request and responds. For example, if the user (client) makes a request to access www.bbc.co.uk to a web server. ​ Large services like Amazon and Google will need very powerful servers to handle millions of requests a second. ​ The client is completely dependent on the server to provide and manage the information. The server controls network security , backups and can be upgraded to manage higher demand. Disadvantages: Large amounts of traffic congestion will cause the network to slow down . If a fault occurs with the server then the whole network will fail . IT technicians may be required to manage and maintain the network . Malware , such as viruses, can spread quickly across the network. Peer-to-Peer Network For peer-to-peer networks , data is shared directly between systems without requiring a central server . Each computer is equally responsible for providing data. Peer to peer is optimal for sharing files that can then be downloaded. Bus Topology The nodes are connected to a bus (a central cable which transfers all data on the network). How it works: The bus transfers data packets along the cable . As the data packets arrive at each computer system, the computer checks the destination address contained in the packet to see if it matches its own address . If the address does not match , the computer system passes the data packet to the next system . If the address of the computer system matches the destination address in the data packet, it is accepted and processed. At both ends of the cable are terminators to mark the end of the bus. Advantages: Because of the simple layout, it is easy to attach another system to the main cable without disrupting the whole network . A bus topology is quick to set up once the main cable has been established making it optimal for temporary networks . A bus topology is cost-effective because it usually contains less cabling than other topologies and requires no additional hardware (like a hub or switch). Disadvantages: Poor security as data packets are passed on to each system on the network. Data collisions are likely - this is when two systems attempt to transfer data on the same line at the exact same time. Resending the data wastes time and slows down the network . The main cable will only have a limited length which can become crowded and slows network speed as more systems are attached. The main cable must also be terminated properly . Token Ring Topology In a token ring network , computer systems are connected in a ring or a loop. How it works: A token (small data packet) is sent around the ring in one direction, being passed from one computer system to the next. A computer seizes the token and includes its own data when it transfers data. As the token arrives at each computer system, the system checks the destination address contained in the packet to see if it matches its own. If the addresses match, the computer processes the data otherwise it ignores it. Advantages: Data collisions are avoided as data packets are transmitted in one direction around the ring. Attaching more systems to a ring topology won't affect the transfer speed as much as other layouts like a bus topology because the data is transferred at a consistent speed . Disadvantages: If any system on the network fails then the whole network fails as the loop is broken and data can't be transferred to all systems. To add a new system to a ring topology the network must be temporarily shut down . Star Topology In a star network , each computer system is connected to a central node: a hub or switch . How it works: Each node is connected to the central node (usually a hub or switch ) and transfers its data packets here. The hub/switch looks at the destination address and transfers the packets to the intended computer only. Advantages: A star topology has improved security because data packets are sent directly to and from the hub / switch in the centre and not necessarily all devices like in a bus or ring topology. New systems can be attached directly to the central system so the network doesn't need to be shut down . System failures of attached computers won't usually cause complete network failure. Transfer speeds are generally fast in a star topology as there are minimal network collisions . Disadvantages: Extra hardware (the hub or switch) is required to be purchased, installed and maintained. If the central system (the hub or switch) fails then the whole network will be unusable until the error is fixed. Mesh Topology In a mesh network, each computer system is connected to every other computer system . How it works: Data packets are transferred to the destination address along the quickest path, travelling from node to node. If a pathway is broken, there are many alternative paths that the packets can take. Advantages: If one cable or system fails then data packets can take an alternative route and still reach the destination address. Because of the large possible number of systems and connections, a mesh topology can usually withstand large amounts of data traffic . New systems can be added to the network without disrupting the entire topology . Disadvantages: Because of the possibly large amount of cables required (especially in a complete mesh topology) this network layout can be expensive to install and maintain . Redundant cabling should be avoided - this is when cables are connected between systems that won't ever need to communicate . Configuration Before a computer system can use a network, three pieces of information must be configured (set up) correctly. IP Address An IP address is used to uniquely identify computer systems on a network , allowing communication between them. ​ ​An example of an IP address is 195.10.213.120. Default Gateway When data is to be sent from one network to another , it must be sent through a default gateway . This default gateway is usually a router that connects the local network to another network. Network managers can use automatic configuration which is quicker and easier to set up . ​ A new device can connect to and use a network automatically , such as free WiFi in an airport. Network managers can also set manual configuration which improves security as new devices can’t be used until the addresses have been configured by a technician . This stops unauthorised devices from connecting to the network. Subnet Mask Subnetting is the act of dividing a physical network into smaller 'sub' networks (known as subnets ) . This helps to reduce traffic and means that users can externally access parts of a network (e.g. emails from home) without having to open the entire network. ​ A subnet mask is used to define these subnets . The mask is used to determine the start and end address of each IP address in a subnet. ​ A common subnet mask is 255.255.255.0 as making the first 3 sections full restricts the fourth section to 256 unique values. For example 113.12.14.230 and 113.12.14.157 are in the same subnet but 114.12.14.127 wouldn't be. Q uesto's Q uestions 3.3 - Network Characteristics: ​ 1 a. Describe how peer-to-peer networks and client-server networks function. 1b. Give one use for both types of network. ​ ​ 2a. Draw and label a diagram for all 6 network topologies . 2b. Describe 2 advantages and 2 disadvantages of each network topology . ​ 3 . What is an IP address ? Why is it necessary for networks? 4. Describe what is meant by a default gateway . 5a. What is subnetting ? 5b. What is the purpose of a subnet mask ? 5c. State a common subnet mask . How many unique devices can be used on a network with this subnet mask? 6. Describe 1 reason why a network manager may use automatic configuration and 1 reason why they may use manual configuration . Advantages: The network can be controlled centrally from the server to easily backup data and update software . Hardware, software and resources can be shared across the network, such as printers, applications and data files . The network allows for improved scalability , meaning more clients can be easily added to the central server . Disadvantages: Without a dedicated server there is no central device to manage security or backups . Backups must be performed on each individual system. Computer performance will decrease with more devices connected to the network, especially if other machines are slow. Advantages: This is a simpler network than client-server to set up as no server is required . Clients are not dependent on a server . Perfect for quickly sharing files between systems , such as downloading media files. 3.2 - Virtualisation Topic List 3.4 - Connection Methods
- Greenfoot Tutorial | CSNewbs
A Tutorial to Creating a Greenfoot Game Greenfoot Home Greenfoot is software that uses the programming language Java to make simple games. ​ This is called object-orientated programming (OOP ) because objects are coded to interact in a visual environment. ​ Work your way through the following tutorial to create a game similar to one required in the WJEC/Eduqas 2016 specification Component 2 exam . ​ ​ Topic Links: Starting from Scratch & Populating the World Move with Arrow Keys Move Randomly & Bounce on Edge Remove Objects Play Sounds The Counter Extension Ideas According to the 2016 specification, in the Eduqas exam, you will use Greenfoot version 2.4.2 , despite the fact that Greenfoot is now on version 3.6.1 . ​ This means that some newer code won't work! This guide here will work on version 2.4.2 . ​ Just make sure you are also using version 2.4.2 - see the download page for help. Watch on YouTube:
- 2.2 - Secondary Storage - OCR GCSE (J277 Spec) | CSNewbs
2.2: Secondary Storage Exam Board: OCR Specification: J277 Secondary storage is non-volatile storage used to save and store data that can be accessed repeatedly. ​ ​ Secondary storage is not directly embedded on the motherboard (and possibly even external ) and therefore further away from the CPU so it is slower to access then primary storage . Storage Characteristics you should know: ​ CAPACITY : The maximum amount of data that can be stored on the device. DURABILITY : The strength of the device, to last without breaking . PORTABILITY : How easy it is to carry the device around . ACCESS SPEED : How quickly data on the device can be read or edited . COST : The average price it costs to purchase the storage device. ​ RELIABILITY : The likelihood of the device continuing to perform well over time . Magnetic Storage A magnetic hard disk drive (HDD ) is the most common form of secondary storage within desktop computers. A read/write head moves nanometres above the disk platter and uses the magnetic field of the platter to read or edit data. An obsolete (no longer used) type of magnetic storage is a floppy disk but these have been replaced by solid state devices such as USB sticks which are much faster and have a much higher capacity. Another type of magnetic storage that is still used is magnetic tape . Magnetic tape has a high storage capacity but data has to be accessed in order (serial access ) so it is generally only used by companies to back up or archive large amounts of data . Magnetic Storage Characteristics (Hard Disk Drive): ​ ✓ - Large CAPACITY and cheaper COST per gigabyte than solid state . ​ ✓ - Modern external HDDs are small and well protected so they are DURABLE and PORTABLE , however because of the moving parts, they should not be moved when powered on because it can damage the device. ​ X - Slower ACCESS SPEED than solid state but faster than optical storage . ​ Optical Storage Optical storage uses a laser to project beams of light onto a spinning disc, allowing it to read data from a CD , DVD or Blu-Ray . ​ This makes optical storage the slowest of the four types of secondary storage. ​ Disc drives are traditionally internal but external disc drives can be bought for devices like laptops. ​ Magnetic Disks are spelled with a k and Optical Discs have a c. Optical Storage Characteristics: ​ X - Low CAPACITY : 700 MB (CD ), 4.7 GB (DVD ), 25 GB (Blu-ray ). X - Not DURABLE because discs are very fragile and can break or scratch easily. ✓ - Discs are thin and very PORTABLE . Also very cheap to buy in bulk. ​ X - Optical discs have the Slowest ACCESS SPEED . Solid State Storage There are no moving parts in solid state storage. SSD s (Solid State Drives ) are replacing magnetic HDDs (Hard DIsk Drives) in modern computers and video game consoles because they are generally quieter , faster and use less power . ​ A USB flash drive ( USB stick ) is another type of solid state storage that is used to transport files easily because of its small size. ​ Memory cards , like the SD card in a digital camera or a Micro SD card in a smartphone , are another example of solid state storage. Solid State Characteristics: ​ X - More expensive COST per gigabyte than magnetic . ​ ✓ - Usually DURABLE but cheap USB sticks can snap or break . ​ ✓ - The small size of USB sticks and memory cards mean they are very PORTABLE and can fit easily in a bag or pocket. ​ ✓ - Solid State storage have a high CAPACITY and the fastest ACCESS SPEED because they contain no moving parts . Q uesto's Q uestions 2.2 - Secondary Storage: ​ 1. Rank magnetic , optical and solid-state storage in terms of capacity , durability , portability , speed and cost . For example, magnetic has the highest capacity , then solid-state, then optical. This could be completed in a table . [15 ] ​ 2. Justify which secondary storage should be used in each scenario and why it is the most appropriate: a. Sending videos and pictures to family in Australia through the post . [ 2 ] b. Storing a presentation to take into school . [ 2 ] c. Storing project files with other members of a group to work on together . [ 2 ] d. Backing up an old computer with thousands of files to a storage device. [ 2 ] 2.1 - Primary Storage Theory Topics 2.3 - Data Units
- 3.5 - Data Analysis Tools | Unit 2 | OCR Cambridge Technicals | CSNewbs
3.5 - Data Analysis Tools Exam Board: OCR Specification: 2016 - Unit 2 The fifth stage of data analysis is to select the most appropriate tools to analyse the collected data. The method(s) selected will depend on the type of project and the established objectives. Data Tables Databases are often split into tables to be easier to update , view and manipulate . For example, a supermarket database may include a table of product information, another table of suppliers and another for actual stock levels. Separating the data into tables allows for simpler editing and also allows for the display of basic patterns . For example, looking at a table of stock levels in a supermarket can quickly show which products need to be ordered in as they are close to selling out. ​ Data tables allow for the most simple form of pattern discovery and are a good method of speedy, short-term data analysis . However they present data in its current format and cannot show change or trends over time - a product may have a high stock level because it is popular and has just been ordered in, rather than because no-one is buying it. A simplified data table for a supermarket. Visualisation of Data Visualising data (by producing a chart or graph of collected data for example) makes it easier for an audience to see trends and patterns . Visualising data, like the bar chart to the right of the supermarket table from the tool above, makes it easier to understand and quicker to interpret . In this example, It is easier to see using the chart that steak pies are low in stock and should be re-ordered soon. A bar chart of the supermarket data table. Trend & Pattern Identification This tool links heavily to visualisation of data in allowing trends and patterns to be viewed as a visual format - such as producing a line graph of last year’s stock sales. ​ Statistical analysis allows data analysts to examine numerical data and, if done correctly, can highlight relationships between different data elements - such as the price of a product and how many have been sold. Discovering links between variables is known as regression analysis . Data Cleaning Data cleaning ensures that any stored data is up-to-date and accurate , in accordance with the Data Protection Act ( 2018 ). Forms of data cleaning include removing customers who have not made a purchase in a certain amount of time (e.g. two years) and periodically checking that user addresses are up to date. ​ Data cleaning would reduce the size of any data table by removing redundant, incorrect or unnecessary data . This would make it easier to work with the data table and would improve the data quality by removing erroneous and irrelevant data. GIS / Location Mapping Geographic Information Systems (GIS ) can be used to add geographic data to any analysis. For example, an organisation can track the geographical location of items or staff e.g. tracking the movement of shipping containers around the world to see production flow. This also works for courier services to see delays and delivery times in real-time . Q uesto's Q uestions 3.5 - Data Analysis Tools: ​ 1. Describe how Fresh Food UK, from the question in 3.4 , could use each of the data analysis tools when trying to determine and present the most profitable stores across the country in the past year . ​ a. Data Tables [3 ] b. Visualisation of Data [3 ] c. Trend & Pattern Identification [3 ] d. Data Cleaning [3 ] e. GIS / Location Mapping [3 ] 3.4 - Stages of Data Analysis Topic List 3.6 - Information Systems
- 4.2 - Global Legislation | Unit 2 | OCR Cambridge Technicals | CSNewbs
4.2 - Global Legislation Exam Board: OCR Specification: 2016 - Unit 2 Data Protection Outside of the UK Personal data should not be transferred outside of the UK unless the country receiving the data has adequate data protection laws that match the Data Protection Act (2018) / GDPR (General Data Protection Regulation ). ​ GDPR was introduced in all European Union (EU ) countries in 2018. This set of regulations ensure that personal data is protected and can be sent between EU countries. However, many other countries only have partially adequate data protection laws (such as the USA and Canada) whilst many nations have inadequate or no laws regarding data protection. Click the map button to visit CNIL's website and see exactly which countries have adequate, inadequate and no data protection laws. UNCRPD UNCRPD stands for United Nations Convention on the Rights of Persons with Disabilities . This is a United Nations human right that states disabled people should be able to 'access information systems' (article 9) and 'use digital means to express their opinion' (article 21). Methods of complying with this convention include:​ Personal data can be sent between European countries (such as the UK) and the United States because of a protection scheme which was known as the 'Safe Harbour ' scheme (between 2000 and 2015) and the 'EU-US Privacy Shield ' (between 2015 and 2020). ​ This provided protection to European data in the US and required both companies engaged in data transaction to sign up to the scheme before personal data could be transferred. The companies must have been assessed as responsible for the security of the data. ​ The scheme was stopped in July 2020 because the European Court of Justice argued it did not adequately protect the personal data of Europeans from government access. Using < alt> text on images so that text-to-speech software can describe the image aloud, for the visually impaired . The tag can be added to the HTML code of an image on a website and will be audibly spoken by specialist reading software. This image contains alt text that can't be seen by a typical viewer but will be read aloud by screen reading software. Accessibility settings . Websites could allow users to change the font size and style or change the background colour to make text easier to read . Wikipedia presents some articles to be listened to if the user is unable to read them. Example Text Example Text Example Text Example Text Q uesto's Q uestions 4.2 - Global Legislation: ​ 1a. What is the problem with transferring data outside of the UK ? [2 ] 1b. Why can personal data be transferred between European countries ? [2 ] ​ 2. Open the CNIL map (use the link on this page and click on a specific country to see its name) and state: Four countries in the EU Two countries with partially adequate protection Two countries with an authority and law (dark purple) Two countries with laws only (light purple) Four countries with no data protection laws [7 ] ​ 3a. What is UNCRPD and why is it important ? [3 ] 3b. Describe what alt text is used for. [2 ] 3c. State three accessibility settings that could affect how easy text is to read . [3 ] EU-US Privacy Shield 4.1 - UK Legislation Topic List 4.3 - Green IT
- Python | 9a - String Handling | CSNewbs
top Python 9a - String Handling What is String Handling? String handling refers to the manipulation of a string variable , typical uses include: ​ Checking the length of a variable. Searching a variable for a certain phrase. Checking the number of times a specific character or word is used . ​ String handling is used to examine passwords and to ensure that they are of an acceptable strength (e.g. by checking that they are at least 8 characters in length and include a mixture of capital letters , lowercase letters and symbols ). Password: arsenal Password: $tr0nG_pA$$w0rd Lowercase & Uppercase .lower() and .upper() are functions that convert a string into a fully lowercase or uppercase version. dogbreed = "Chihuahua" print (dogbreed.upper()) CHIHUAHUA character = "sPoNgeBoB" print (character.lower()) spongebob You may have realised that Python is very specific . 'yes ', 'Yes ' and 'YES ' are all treated as different values . ​ Converting user input into one case , such as lowercase, and then comparing that input is a better way of checking an input than having an if statement with multiple or comparisons. The program below converts the user input into lowercase to compare. 'yes', 'Yes' and 'YES' are all converted to 'yes'. answer = input ( "Would you like water? " ) answer = answer.lower() if answer == "yes" : print ( "I'll fetch you a glass." ) else : print ( "Don't dehydrate!" ) Would you like water? yes I'll fetch you a glass. Would you like water? Yes I'll fetch you a glass. Would you like water? YES I'll fetch you a glass. Practice Task 1 Ask the user to enter their first name and surname. Print their surname in uppercase followed by their first name in lowercase. Example solution: Enter First Name: Jayden Enter Surname: Hargrove Welcome HARGROVE, jayden Count Characters The easiest way to count how many times a certain value appears within a string is to use the .count() command. It is important to note that, just like when using an input statement or calculation line, you must save the calculation into a variable . An example, for counting the number of e’s in a sentence, is below: sentence = input ( "Enter your sentence: " ) e_count = sentence.count( "e" ) print ( "There were" , e_count, "e's in your sentence!" ) Enter your sentence: even ellie eats elderberries There were 9 e's in your sentence! Practice Task 2 Create a program that counts how many instances of the letter a have been entered in a sentence. Bonus: Use the .lower() function in your code to include capital letters. Example solution: Enter a sentence: An angry aardvark named Aaron. That sentence had 8 a's. Finding the Length of a String Just like when we wanted to find the length of a list, we use the len command to see how many characters are in a string . It is sensible to save the result of the function into a variable so it can be used later . fruit = input ( "Enter a fruit: " ) length = len (fruit) print ( "That fruit was" , length, "characters." ) Enter a fruit: pineapple That fruit was 9 characters. A common reason for finding the length is as part of validation , for example, checking a password is more than 8 characters : password = input ( "Enter a new password: " ) length = len (password) if length >= 8: print ( "Password accepted!" ) else : print ( "Password is too short, must be at least 8 characters." ) Enter a password: snake54 Password is too short, must be at least 8 characters. Enter a password: pebblesthedog76 Password accepted! Practice Task 3 Create a program that asks for a name. Check that the name is between 4 and 10 characters. Print appropriate messages if it is within this range and if it isn't. Example solution: Enter a name: Tom That name is too short, it must be between 4 and 10 characters. Checking the Start / End of a String To determine if the first character in a string is a specific value use the .startswith() command. ​ .startswith() is a function that will return True or False . ​ Below is an example program to check if a name begins with the letter L . name = input ( "Enter a name: " ) if name.startswith( "L" ) == True : print ( "I like that name." ) else : print ( "I don't like that name." ) Enter a name: Lionel I like that name. Enter a name: Katjaa I don't like that name. Similarly, you can use .endswith() to check the last characters of a string . Practice Task 4 Ask the user to enter a country. Print a message if it ends with 'land', 'stan' or any other ending. Use .endswith() Example solution: Enter a country: Finland You have entered a 'land' country. There are 9 in the world. Enter a country: Kyrgyzstan You have entered a 'stan' country. There are 7 in the world. Enter a country: Peru Thanks for your entry. Note: You don't need to check if it's a valid country. Reversing a String To reverse a string, you write the variable name and then use square brackets to move one character at a time backwards. The first two colons are left empty as they denote where to start and end from (which don’t need to be changed). ​ Therefore the -1 states that it will reverse from the end to the start : Ask the user to enter a random sentence. ​ Print the sentence in reverse. Example solution: Practice Task 5 Printing Parts of a String You may want to print just part of a string or variable using square brackets. You can also use len to work out the length and work back, if you want to display the last characters: Practice Task 6 Ask the user to input a long word. ​ Output the middle character of the word. Example solution: Split Strings Use the .split command to split a string into separate words . ​ An empty split command such as words.split() will split at each space . You can enter a value in the brackets to split at certain characters , such as words.split(",") Use the len function to count the number of words once they have been split. You can use a for loop to cycle through each word. The program below checks the length of each word . Practice Task 7 Ask the user to input a sentence. ​ Calculate and print the amount of words in the sentence. ​ Calculate and print the amount of words that begin with s. Example solution: ⬅ Section 8 Practice Tasks 9b - Number Handling ➡
- Computer Science Newbies
C omputer S cience P ros Official 2024 CSPros: Jack Harry Aarav Trisha Mario Hiba Rory Clark Lucy Divya Luke Callum James Zoya Timucin Matthew 2023 CSPros: Henry Zain Iman Alex I-C Alex B Tomos Aidan Rahul Hussain Diyar Sam Harry Will Alex H 2022 CSPros: Logan Eleanor Mark Edward Alfie Henry Enzo Sam George Harry Ella Kav