Answer:
Load balancing is the mechanism happening between the different components to achieve the aim independently in the server. They are not aware of the presence of the other resources with them.
Clustering is the process in which the components work to gain the desired results in the form of group.They work in group so that there are no chances of crash in server.
The similarity arises between these two process are :
- They have capability to work even after failure of system
- Can have unnecessary access to the information
- Scalable
Answer and Explanation:
Using javascript:
function dayof_theweek(){
var TodayDate = window. prompt("enter today's date in the format 'year, month, day' ");
var Datenow=new date(TodayDate);
var Dayofweek=Datenow.getday();
var Days=["monday","Tuesday", "Wednesday", "Thursday", "Friday", "Saturday", "Sunday"];
if(Dayofweek==indexOf(Days[Dayofweek]))
{
document.createTextnode(Days[Dayofweek]);
}
}
The program above uses a date object which uses the method getday to get the day of the week(get day returns an integer from 0 to 6).we then use a comparison operator == to test the condition that returned value Dayoftheweek is same with the index of the array Days and then print to a html document. The program may need improvements such as the fact that errors may arise when proper input isn't given, and therefore must be handled.
A check box is a user-interface (UI) component with two states; checked and unchecked.
Explanation:
the output of your code is 30