Programming question and answers for July 13, 2023
- Q A successful new user registration requires the following validdata:â¦Â  User name: it must start with a letter and consistof only letters and digits without any space character. User nameis case...
- Q Create two functions that you can use for a dictionarymanager:1. remove_item(dictionary,key): a function that removes the itemwith the supplied key from the dictionary, if it exits. If theinput key doesn’t...
- Q JAVA questionA string may use more than one type of delimiter to bracketinformation into \"blocks\". The primary ways to divide things upinto block is by the braces { } ,...
- Q The Random class implements a random number generator, whichproduces sequences of numbers that appear to be random. To generaterandom integers, you construct an object of the Random class, andthen apply...
- Q Compare the following pairs of methods/techniques:Time stamping vs. optimistic methods in distributed systems
- Q In python, read the file credit_cards.txt into a dictionary withthe count of how many cards of each type of card are in thefile.credit_cards.txt contains the following data:John Smith, DiscoverHelen Jones,...
- Q Write minimal code to declare a class Complex that enablesoperations on complex numbers, and also to overload themultiplication * operator.
- Q Write the EBNF for mini Java language based ofthe following information:Data TypesIntegerIntLongDoubleBooleanCharReferencesComplex Data StructuresArraysint v[30];Classesmember variablesclass Name {int a;char b;char name[25];}MethodsReturn data typePrimitive data typeVoidMethod NameParameter listCould be emptyStatement Block{Variable...
- Q Modify HW#1. C++ use,Write a multithreaded program that testsyour solution to HW#1. You will create several threads – forexample, 100 – and each thread will request a pid, sleep for...
- Q Print \"Hello World\" in the most complicated way(java)
- Q An English word iscalled palindrome if its meaning may be interpreted the same way ineither forward or reverse direction. Some examples of commonpalindromic words: civic, radar, level,rotor, noon, etc.Design an...
- Q Write a C program that does the following.(a) Start with comment statements at the top (before yourincludes) with the following info: Name, Date(b) Write the following functions:void setupRandArray(int n, int...
- Q Answer the following: a) What is a critical region? b) How cancounting semaphores be used to provide exclusive access to acritical region? c) Describe the operation (clearly, in English) ofthe...
- Q Let’s revisit the Fibonacci sequence, this time without anarray. Recall that the sequence is defined by the followingrecurrence relation: F0 = 0 F1 = 1 Fk = Fk-1 + Fk-2...
- Q Write the correct code in SQL1. What is the name and address of the customer that placedorder 57?2. Assume there is only one product with the description CherryEnd Table. List...
- Q (This is for java)I need to rewrite this code that uses a while loop.public class Practice6 {Â Â Â Â public static void main (String [] args){Â Â Â Â Â Â Â int sum = 2, i=2;Â Â Â Â Â Â do...
- Q What is the output of the following C program?#include<stdio.h>int fac (int x);void main( ){Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â for (int i=1; i<=2; i++)Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â printf(\"%d\", fac(i));}int fac(int x){Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â x = (x>1) ? x + fac(x-1) : 100);Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â Â return x;}
- Q How can businesses and organizations continue to respect legaland ethical concerns while still permitting the use of predictiveanalytics to drive business value? Identify and discuss some legalor ethical practices that...
- Q 111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111Find the tightest asymptotic bounds you can for the recurrences,assume that T(1) = constant.T(n) = 4T(n/2) + (n^2)log nT(n) =T(n−1) + T(n/2) +n
- Q Modify the below program so that the following two conditionsare met:1. Each child terminates abnormally after attempting to write toa location in the read-only text segment.2. The parent prints output...
- Q Write an assembly program In MASM assembler to calculate the sum of odd numbers only stored in a 16-bit integers array.The size of the array is provided in a separate...
- Q Write a batch program that takes and echoes input data onecharacter at a time until EOF is encountered and then prints asummary such asThe 14 lines of text processed contained...
- Q In PythonFind the errors, debug the program, and then execute to show theoutput.def main():Â Â Â Calories1 = input( \"How many calories are in thefirst food?\")Â Â Â Calories2 = input( \"How many calories...
- Q C++Write a function that accepts an array of doubles and thearray's size as arguments. The function should display the contentsof the array to the screen.
- Q C PROGRAM STRING AND FILE PROCESSINGLEAVE COMMENTS! I WILL LEAVE POSITIVEREVIEW! THANK YOU :)I need a program that1) Count all words in a file. A word is any sequence ofcharacters...
Get Answers to Unlimited Questions
Join us to gain access to millions of questions and expert answers. Enjoy exclusive benefits tailored just for you!
Membership Benefits:
- Unlimited Question Access with detailed Answers
- Zin AI - 3 Million Words
- 10 Dall-E 3 Images
- 20 Plot Generations
- Conversation with Dialogue Memory
- No Ads, Ever!
- Access to Our Best AI Platform: Flex AI - Your personal assistant for all your inquiries!