Answer:
Cyber security is the application of technologies, processes and controls to protect systems, networks, programs, devices and data from cyber attacks. It aims to reduce the risk of cyber attacks and protect against the unauthorised exploitation of systems, networks and technologies.
Answer:
God is always your friend mate
Explanation:
Answer:
The solution code is written in Java.
- public class Main {
- public static void main(String[] args) {
- int n = 5;
- int j;
- do{
- System.out.print("*");
- n--;
- }while(n > 0);
- }
- }
Explanation:
Firstly, declare the variable n and assign it with value 5 (Line 4). Next declare another variable j.
Next, we create a do while loop to print the n-number of asterisks in one line using print method. In each iteration one "*" will be printed and proceed to the next iteration to print another "*" till the end of the loop. This is important to decrement the n by one before the end of a loop (Line 9) to ensure the loop will only run for n times.
Go slow and be careful of your surroundings
Answer:
- var count = 0;
- var counterElement = document.getElementById("counter");
- counterElement.innerHTML = count;
- var a = setInterval(
- function(){
- count++;
- counterElement.innerHTML = count;
- if(count == 5){
- clearInterval(a);
- }
- }
- , 300);
Explanation:
The solution code is given from Line 6 - 15.
setInterval function is a function that will repeatedly call its inner function for an interval of time. This function will take two input, an inner function and the interval time in milliseconds.
In this case, we define an inner function that will increment count by one (Line 8) and then display it to html page (Line 9). This inner function will repeatedly be called for 300 milliseconds. When the count reaches 5, use clearInterval to stop the innerFunction from running (Line 11 - 13).