Questions
Active Directory Domain Services Installation Wizard

Active Directory Domain Services Installation Wizard

In: Computer Science

write a c# console application app that reads all the services in the task manager and...

write a c# console application app that reads all the services in the task manager and automatically saves what was read in a Notepad txt file.  Please make sure that this program runs, also add some comments

In: Computer Science

Personal Use of Technology:- Create a list of at least 4 examples of technologies used by...

Personal Use of Technology:-

Create a list of at least 4 examples of technologies used by you within the last 2 months.  

For each:

Classify them by IT Component types


Research and identify approximately what year each technology was introduced, and when your specific version was introduced.


Indicate how you have used the technology.  


Indicate what your next-best alternate would have been if you did not have the technology. Estimate the associated impact to you if you did not have the technology (additional time, cost to you per day/week etc.)


Indicate 1 example of something you currently do manually (and that there currently is not a technology solution available yet). Investigate if anyone in the world is already innovating and working on it, and if so, provide a reference (name and link) and some details.

Response should be in table form, 1-3 pages max.

In: Computer Science

Assume that 40% of a program is parallelizable. In 15% of the parallel portion, 200x speed...

Assume that 40% of a program is parallelizable. In 15% of the parallel portion, 200x speed up has achieved. And in the 25% of the parallel portion 300x speed up has achieved

What is the overall speed up for that program?
What is the overall speed up if we could achieve infinite speed up for 40% of the program?

In: Computer Science

Create a new file name condition_quiz.py. Add a comment with your name and the date. Prompt...

  1. Create a new file name condition_quiz.py.

  2. Add a comment with your name and the date.

  3. Prompt the user to enter the cost. Convert the input to a float.

  4. Prompt the user for a status. Convert the status to an integer

  5. Compute the special_fee based on the status.

If the status is 0, the special_fee will be 0.03 of the cost.

Else if the status is 1, the special_fee will be 0.04 of the cost.

Else if the status is 2, the special_fee will be 0.06 of the cost.

Else if the status is 3 or 4, the special_fee, the special_fee will be 0.07 of the cost.

Otherwise, the special_fee will be 0.10 of the cost.

  1. Compute the total_cost as the cost plus the special_fee. Print out the total_cost with two decimal places of precision.

In: Computer Science

Please use java language in an easy way and comment as much as you can! Thanks...

Please use java language in an easy way and comment as much as you can! Thanks

  1. (Write a code question) Write a generic method called "findMin" that takes an array of Comparable objects as a parameter. (Use proper syntax, so that no type checking warnings are generated by the compiler.) The method should search the array and return the index of the smallest value.

  2. (Analysis of Algorithms question) Determine the growth function and time complexity (in Big-Oh notation) of the findMin method from the previous problem. Please show your work by annotating the code.

In: Computer Science

ENCODE THE FOLLOWING STREAM OF BITS USING 4B/5B encoding :- 1101011011101111 what is the ratio of...

ENCODE THE FOLLOWING STREAM OF BITS USING 4B/5B encoding :-

1101011011101111

what is the ratio of redundant bits in 4B/5B?

In: Computer Science

1. Write a python program to create a list of integers using random function. Use map...

1. Write a python program to create a list of integers using random function. Use map function to process the list on the expression: 3x2+4x+5 and store the mapped elements in another list. Now use filter to do sum of all the elements in another list.

2. Write a function that takes n as input and creates a list of n lists such that ith list contains first 10 multiples of i.

3. Write a function that takes a number as input parameter and returns the corresponding text in word. For example, on input 458, the function should return ‘Four Five Eight’. Use dictionary for mapping digits to their string representation.

4. Write a program to create two sets of integer type using random function. Perform following operations on these two sets:

a) Union

b) Intersection

c) Difference

d) Symmetric difference

In: Computer Science

can someome investigate my program that utilizes semaphores that can result in deadlock due to programming...

can someome investigate my program that utilizes semaphores that can result in deadlock due to programming errors and help in finding out if the solution meet all criteria for the critical section
  • If yes, then comment code identifying the parts of code that do
  • If no, could you help in fixing the code wherever given solution fails criteria in the code below

#include <pthread.h>
#include <semaphore.h>
#include <stdio.h>
#include <unistd.h>

#define N 5
#define THINKING 2
#define HUNGRY 1
#define EATING 0
#define LEFT (phnum + 4) % N
#define RIGHT (phnum + 1) % N

int state[N];
int phil[N] = { 0, 1, 2, 3, 4 };

sem_t mutex;
sem_t S[N];

void test(int phnum)
{
if (state[phnum] == HUNGRY
&& state[LEFT] != EATING
&& state[RIGHT] != EATING) {
// state that eating
state[phnum] = EATING;

sleep(2);

printf("Philosopher %d takes fork %d and %d\n",
phnum + 1, LEFT + 1, phnum + 1);

printf("Philosopher %d is Eating\n", phnum + 1);

// sem_post(&S[phnum]) has no effect
// during takefork
// used to wake up hungry philosophers
// during putfork
sem_post(&S[phnum]);
}
}

// take up chopsticks
void take_fork(int phnum)
{

sem_wait(&mutex);

// state that hungry
state[phnum] = HUNGRY;

printf("Philosopher %d is Hungry\n", phnum + 1);

// eat if neighbours are not eating
test(phnum);

sem_post(&mutex);

// if unable to eat wait to be signalled
sem_wait(&S[phnum]);

sleep(1);
}

// put down chopsticks
void put_fork(int phnum)
{

sem_wait(&mutex);

// state that thinking
state[phnum] = THINKING;

printf("Philosopher %d putting fork %d and %d down\n",
phnum + 1, LEFT + 1, phnum + 1);
printf("Philosopher %d is thinking\n", phnum + 1);

test(LEFT);
test(RIGHT);

sem_post(&mutex);
}

void* philospher(void* num)
{

while (1) {

int* i = num;

sleep(1);

take_fork(*i);

sleep(0);

put_fork(*i);
}
}

int main()
{

int i;
pthread_t thread_id[N];

// initialize the semaphores
sem_init(&mutex, 0, 1);

for (i = 0; i < N; i++)

sem_init(&S[i], 0, 0);

for (i = 0; i < N; i++) {

// create philosopher processes
pthread_create(&thread_id[i], NULL,
philospher, &phil[i]);

printf("Philosopher %d is thinking\n", i + 1);
}

for (i = 0; i < N; i++)

pthread_join(thread_id[i], NULL);
}

In: Computer Science

There are at least five (probably more) places in the attached C# program code that could...

There are at least five (probably more) places in the attached C# program code that could be optimized. Find at least five things in the Program.cs file that can be changed to make the program as efficient as possible.

  1. List five problems you found with the code (Put your list either in comments within the code or in a separate Word or text document), and then optimize the code in the attached code below to make it as efficient as possible. The program output must not be affected by your changes. To the user it should still do everything it did before your changes provided the user enters valid data.

using System;

namespace COMS_340_L4A
{
class Program
{
static void Main(string[] args)
{
Console.Write("How many doughnuts do you need for the first convention? ");
int.TryParse(Console.ReadLine(), out int total1);

Console.Write("How many doughnuts do you need for the second convention? ");
int.TryParse(Console.ReadLine(), out int total2);

int totalDonuts = Calculator.CalculateSum(new int[] { total1, total2 });

Console.WriteLine($"{ totalDonuts } doughnuts is { Calculator.ConvertToDozen(totalDonuts)} dozen.");
Console.WriteLine("Press Enter to quit...");
Console.ReadLine();
}
}

static class Calculator
{
static int DOZEN = 12;

public static int CalculateSum(int[] args)
{
int return_value = 0;
foreach (int i in args)
{
return_value += i;
}
return return_value;
}

public static int ConvertToDozen(int total)
{
int dozen = DOZEN;
return total / dozen;
}
}
}

In: Computer Science

1.) Simplify the following expression to a minimum number of literals. This problem must be solved...

1.) Simplify the following expression to a minimum number of literals. 
This problem must be solved through Algebraic Manipulation.
All work must be shown on the submitted work. 
Things to remember. 
 If you can't see anything to work with from the beginning, expand.
 Formula Sheet has been provided. 

a.) Simplify (you MUST submit your work to get credit for this problem)
F(a, b, c) = bc + a’b + ab’ + ac’

2.) Express the given function in terms of its minterms and Maxterms. You may use a truth table or algebraic manipulation to determine your solution. F(a, b, c) = abc’ + a’c’ + ab’ + b’c

a.)F(a, b, c) =   ∑m( #, #, ... , #)

b.) Write out the full expression for the Product of Maxterms. DO NOT use the Pi notation, ∏M (#, #, ... #).

(i.e. (...) (...) .... (...) )

In: Computer Science

Which of the following two statements are correct? The prediction performance of a model increases monotonically...

Which of the following two statements are correct?

The prediction performance of a model increases monotonically with the number of features used in the model

Clustering in a high dimensional space is challenging because there tends to be limited variation in pairwise distance of data points

The amount of data needed to produce reliable results grows exponentially with the number of dimensions

Suppose we collect a dataset with a billion users and each user has 10 features, we may run into the issue of curse of dimensionality

In: Computer Science

I keep getting minor errors I can't figure out and I don't know how to convert...

I keep getting minor errors I can't figure out and I don't know how to convert decimal .10 to percentage 10% either.  
With these functions defined now expand the program for a company who gives discounts on items bought in bulk.
Create a main function and inside of it ask the user how many different items they are buying.
For each item have the user input a price and quantity, validating them with the functions that you wrote.
Use your discount function to find the discount for each item's quantity and calculate the discounted price.
Print the discounted price in $9,999.99 format

Sum the discounted totals for all items and display this grand total at the end.
Print the percentages in 99.9% format.

In addition to summing the discounted totals, also sum the un-discounted totals.
At the end display both of these values and then calculate and print the overall percentage saved in 99.9% format.

def discount ():
discount = 0.00
if quantity >= 0 and quantity <= 19 :
discount = 0.00
if quantity >= 20 and quantity >= 49 :
discount = 0.05
if quantity >= 50 and quantity <= 99 :
discount = 0.08
if quantity >= 100 :
discount = 0.10
return discount
# user input quantity
def quantity ():
quantity = 0
quantity = int (input ('What is the quantity? '))
while quantity < 1 or quantity > 2000 :
print ('Error, Please enter a quantity between 1 and 2000.')
quantity = int (input ('What is the quantity? '))
return quantity
# user input price
def price ():
price = 0.0
price = float (input ('What is the price? '))
while price < 0.0 :
print ('Error, the price must be greater than $0.00')
price = float (input ('What is the price? '))
return price
# main
def main ():
for i in range (items)   
items = int (input ('How many different items are you purchasing? '))
quantity ()
discount ()
price ()
Total_price = sum (price)
Total_discount = sum (discount)
Discounted_price = price - (price * discount)
Total_Discounted_price = Total_price - (Total_price * Total_discount)
print ('For item ',i +1,,' ' Discounted_price, ' with a ', discount, format (.2f, sep=''))
print ('Total order is ', Total_Discounted_price, ' with a ', Total_discount, format (.2f, sep=''))
#initiate
main ()

In: Computer Science

Part Two: Download VendingChange.java (above). Run it and become familiar with the output. Essentially, you need...

Part Two: Download VendingChange.java (above). Run it and become familiar with the output. Essentially, you need to create a user friendly GUI app using the code parameters of VendingChange. Turn VendingChange.java into a GUI app.

1) Your program must display the input dialog.
2) You must check that the data entered by the user follows the required input. If not, your program must display an error dialog and exit.

3) If the input is valid, then your program must display a message dialog similar to the one shown in listing 2.12, but the message must pertain to VendingChange and not ChangeMaker. Your message dialog must show the number of pennies, nickels, dimes and quarters.
4) Your program must exit when the user closes the output message dialog.
5) Comment and document your program.

Complete the programming problems such that they produce output that looks similar to that shown in the text or upcoming class presentations (in-class and Announcements). Tips and formulas (if any) will be discussed in class. Additional details will be provided in class and Announcements.

add comments to code please.

import java.util.Scanner;

public class VendingChange
{
    public static void main(String[] args)
    {
        Scanner keyboard = new Scanner(System.in);

        System.out.println("Enter price of item");
        System.out.println
                ("(from 25 cents to a dollar, in 5-cent increments)");
        int originalAmount = keyboard.nextInt();
        int change = 100 - originalAmount;

        int quarters = change/25;
        change = change%25;// remaining change after deducting quarters
        int dimes = change/10;
        change = change%10;// remaining change after deducting dimes, too
        int nickels = change/5;
        change = change%5;
        int pennies = change;

        //The grammar will be incorrect if any of the values are 1
        //because the required program statements to handle that
        //situation have not been covered, yet.   
        System.out.println
                ("You bought an item for " + originalAmount
                + " and gave me a dollar,");
        System.out.println("so your change is");
        System.out.println(quarters + " quarters,");
        System.out.println(dimes + " dimes, and");
        System.out.println(nickels + " nickel.");
    }
}

In: Computer Science

*Note: someone else answered the question but queried for the average. I need the median NOT...

*Note: someone else answered the question but queried for the average. I need the median NOT the average. Thanks.

Hi, please help me create the following SQL query:

Create Table A with 1 column and 10 rows. The rows are filled with numbers : 1,2,3,4,5,6,7,8,9,10.

Create Table B with 1 column and 9 rows. The rows are filled with numbers: 1,2,3,4,5,6,7,8,9.

Write a single query that returns the median value of the 10 rows of TableA.

The same query should also work for Table B and return the median value of the 9 rows in Table B.

Expected Answers:

Median for Table A: 5.5

Median for Table B: 5

It would be really helpful if you could include screenshots. Thanks!

In: Computer Science