Answer:
The attached files contain the realization of a D flip-flop from an RS flip-flop. It also contains the truth tables for both kinds of flip-flops
Explanation:
An SR flip flop is like a light switch. Set turns it 'on' and reset turns it 'off'
A D type flip-flop is a clocked flip-flop which has two stable states. A D type flip-flop operates with a delay in input by one clock cycle.
D type flip-flops are easily constructed from an SR flip-flop by simply connecting an inverter between the S and the R inputs so that the input to the inverter is connected to the S input and the output of the inverter is connected to the R input.
Answer:
#here is code in python.
#read number of shares
num_share = int(input("Enter number of shares:"))
#read purchase price
buy_p = float(input("Enter purchase price:"))
#read sell price
sell_p = float(input("Enter sale price:"))
#total buying cost
buy_cost=buy_p*1.03*num_share
#total selling cost
sell_cost=sell_p*0.97*num_share
#if net profit
if(sell_cost>buy_cost):
print("After the transaction, you made " +str(sell_cost-buy_cost)+ " dollars.")
#if net loss
else:
print("After the transaction, you lost " +str(buy_cost-sell_cost)+ " dollars.")
Explanation:
Read the total number of shares from user.Then read buying price of a share and selling price of a share.Then calculate total buying cost including commission.Calculate total selling cost excluding the commission.If total buying cost is greater than total selling cost the print the profit else print the loss in the transaction.
Output:
Enter number of shares:10
Enter purchase price:10
Enter sale price:10
After the transaction, you lost 6.0 dollars.
Answer:
-Consiste en conectar varias redes de computadoras basadas en diferentes protocolos -Requiere la definición de un protocolo de interconexión común sobre los protocolos locales. -El Protocolo de Internet (IP) desempeña este papel, definiendo direcciones únicas para una red y una máquina host.
The exercise contains 15 questions. The solution is provided for each question.
Each question contains the necessary skills you need to learn.
I have added tips and required learning resources for each question, which helps you solve the exercise. When you complete each question, you get more familiar with a control structure, loops, string, and list.
Use Online Code Editor to solve exercise questions.
Also, try to solve the basic Python Quiz for beginners
Exercise 1: Given two integer numbers return their product. If the product is greater than 1000, then return their sum
Reference article for help:
Accept user input in Python
Calculate an Average in Python
Given 1:
number1 = 20
number2 = 30
Expected Output:
The result is 600
Given 2:
number1 = 40
number2 = 30
Expected Output:
The result is 70
Explanation:
Answer:
sibling, fritend, or fellow styu346yhtwf vrrrrrrrgqreg t5