Programming & Computer Science Answers

C++ 9913
Python 5288
Java | JSP | JSF 3611
C 1680
C# 1362
Computer Networks 989
Algorithms 652
Databases | SQL | Oracle | MS Access 641
HTML/JavaScript Web Application 588
Other 537
Visual Basic 358
Assembler 209
Software Engineering 202
AJAX | JavaScript | HTML | PHP 166
MatLAB 150
MatLAB | Mathematica | MathCAD | Maple 124
Action Script | Flash | Flex | ColdFusion 112
UNIX/Linux Programming 89
Web Development 73
Excel 36
ASP | ASP.NET 23
Delphi | Pascal 21
Perl 16
Prolog 9
Functional Programming 9
MathCAD 5
Wolfram Mathematica 4
WPF 4
Ruby | Ruby on Rails 3
NodeJS Web Application 2

Questions answered by Experts: 26 876

Need a fast expert's response?

Submit order

and get a quick answer at the best price

for any assignment or question with DETAILED EXPLANATIONS!

Search

Assuming a message “Exams!” is to be transmitted over a network. If the message is made up of strings with the given probability: e = 0.4, x = 0.1, a = 0.2, m = 0.1, s = 0.1, and ! = 0.1, derive:



a. The codeword using Arithmetic coding procedures



b. The original message by decoding the codeword in (a).




program to convert 6 digits numbers into words


A program is required for a computer game. The user keys in the number of rounds he wishes to play.


For each round the user enters his lucky number. The program takes the number and divides it with a


secret number. If the remainder of the division is zero, it is considered a draw for the round and the total


score is incriminated by 1. Otherwise if it is any other even number, it is considered a win for the round


and the total score is incremented by 3. However if it is an odd number, it is considered a loss for the


round and the total score is decremented by 3. This is done until he completes his rounds. He wins if the


total score at the end is a positive number. Write a Java program to accomplish this.



Give seconds as input,write a program to print in D days H hours M minutes S seconds


Input 200


Output 3 minutes 20seconds


Input 86400


Output 1 day

Assuming a message “Exams!” is to be transmitted over a network. If the message is made up of strings with the given probability: e = 0.4, x = 0.1, a = 0.2, m = 0.1, s = 0.1, and ! = 0.1, derive:

a. The codeword using Arithmetic coding procedures

b. The original message by decoding the codeword in (a).


Consider a mx n matrix inmatrix of string elements containing alphanumeric values, where m>1, n >=1. Identify and print outarr based on the logic below:





• Traverse the inmatrix in clockwise spiral way starting from the element at (0,0) •





traversal until one of the two conditions is met • The element or the concatenated string is a palindrome with length greater





than 1 There are no more elements left for traversal





. Add the concatenated string to outarr





. If there is any element which has not yet been visited in the traversal, repeat the two steps, forming a new concatenated string that starts with the next element present after the last element previously traversed





Note: Perform case-sensitive comparison





Input format:





First line will contain number of rows m of inmatrix





The next m lines will contain the elements of inmatrix. Each line will have n string





elements separated by (comma)

Create a program that reads trom the console two integer numbers (int) and prints now many numbers between them exists, such that remainder of their division by 5 is O. E

write a JS program to

  • filter the candidates who have scored more than 75 points in every even


input

  • the input will be single line containing an array of objects candidatesList

output

  • the output should be single line containing an array with names of the selected candidates.


input1

[{'name': 'Blake Hodges', 'points':[76, 98, 88, 84]}

output1

['Blake Hodges]


"use strict";


process.stdin.resume();

process.stdin.setEncoding("utf-8");


let inputString = "";

let currentLine = 0;


process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});


process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});


function readLine() {

 return inputString[currentLine++];

}


function main() {

 const candidatesList = JSON.parse(readLine().replace(/'/g, '"'));



  

 // Write your code here

}





tax criteria

salary tax percentage

>= 50000 5

>= 1000000 10


quick tip

tax = salary * taxPercentage/100


input 1

stuart

developer

840000


output 1

42000


"use strict";


process.stdin.resume();

process.stdin.setEncoding("utf-8");


let inputString = "";

let currentLine = 0;


process.stdin.on("data", (inputStdin) => {

 inputString += inputStdin;

});


process.stdin.on("end", (_) => {

 inputString = inputString.trim().split("\n").map((str) => str.trim());

 main();

});


function readLine() {

 return inputString[currentLine++];

}


function main() {

 const name = readLine();

 const role = readLine();

 const salary = JSON.parse(readLine());


 function Employee(name, role, salary) {



  // Write your code here


 }


 const employee1 = // Write your code here


/* Please do not modify anything below this line */


 console.log(employee1.getTaxAmount());

}

















Develop a swing application for login validation of a system as shown in the figure. The




application shows two options: one Sign up and another Sign in. When Sign up is selected, a




new screen will appear for asking name, username, password. If the entered username and




password do not exist in the database, it will show a successful message [Name] has




successfully registered and store corresponding username, password in the database,




otherwise the message [Name] already exists in the system will be displayed. On the other




hand, when Sign In option is selected, the user will be prompted to enter username,




password as shown in the figure. Eventually, the application checks whether username and




password both match with some entry in the database. If such entry found in the database,




then a welcome message Welcome [Name] will appear, otherwise an unsuccessful login




message Wrong username/password will be displayed. For message display, the swing dialogs can be used.




LATEST TUTORIALS
APPROVED BY CLIENTS