Python Answers

Questions answered by Experts: 5 288

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

in the example the sentence is Nice Day.

the previous letter of N is M, similarly replace each letter with the previous letter

N i c e D a y

M h b d C z x

so the output should be Mhbd Czx

sample input 1

Nice Day

sample output 1

Mhbd Czx

sample input2

Be good and do good

sample output2

Ad fnnc zmc cn fnnc


Write a program that reads a string and returns a table of the letters of the alphabet in

alphabetical order which occur in the string together with the number of times each letter

occurs. Case should be ignored. A sample output of the program when the user enters the data

“ThiS is String with Upper and lower case Letters”, would look this this:


a 2

c 1

d 1

e 5

g 1

h 2

i 4

l 2

n 2

o 1

p 2

r 4

s 5

t 5

u 1

w 2


I want a very simple code


) Computing the performance of your student class. a) Receive an integer number from user that represents the number of students that he/she has. b) Receive the grades of each student and append them to list call it grades. c) Display for him/her the maximum, minimum, and average grade. d) Display for him/her how many students have the grade between 8-10, 5-7, and below 5


Type the statements below into your Python interpreter. For each statement, copy the output into your Discussion Assignment and explain the output. Compare it with any similar examples in the textbook, and describe what it means about your version of Python. 

>>> print 'Hello, World!'

>>> 1/2

>>> type(1/2)

>>> print(01)

>>> 1/(2/3) 


in the example there are 6 numbers 1,-2,3,-4,-5,6

the negative numbers in the given list are -2,-4 and -5 where the -2 is replaced with corresponding last positive number encountered which is 1.similarly -4 and -5 are replaced with 3

so the output should be 1 1 3 3 3 6

sample input1

1 -2 3 -4 -5 6

sample output1

1 1 3 3 3 6

sample input2

1 11 -13 21 -19

sample output2

1 11 11 21 21


in the example the first test case number is 9966777819 and this number should be divided into 4 3 3 format

the first divided part should be read a double nine double six. As there are two consecutive 9's,it should be read as double nine.similarly there are two consecutive 6's it should be read as double six

in the second divided part there are three consecutive 7's it should be read as triple seven.

In the third divided part there are no consecutive digits each digit should be read separately.

sample input1

9966777819

sample output1

double nine double six triple seven eight one nine

sample input 2

7299613014

sample output 2

seven two double nine six one three zero one four


You are given a string containing ten digits, write a program to print these digits in a human readable format.



There are some rules to how to read a number,



• use the following prefixes for consecutive digits







# Single numbers just read them seperately







# if two successive numbers use double







# if three successive numbers use triple







# if four successive numbers use quadruple

Given an integer N as input, write a program to print a number diamond of 2*N -1 rows.


The number of rows in the diamond is 5.

So the output should be.


1

1 2

1 2 3

1 2 3 4

1 2 3 4 5

1 2 3 4

1 2 3

1 2

1



Write a PYTHON script 


Store https://www.genecards.org/cgi-bin/cardlisttxt.pl it in a flat file.


The GeneCards database currently contains 270,168 GeneCards


Parse the first 10 genes from each series (1A9N_Q-ZZZ3) https://www.genecards.org/cgi-bin/carddisp.pl?gene=GENE NAME


  If the genes are less than 10 then parse all.

Extract Genomic Locations for GENE NAME and store it in a file for each gene you parse.For example  


Open https://www.genecards.org/cgi-bin/carddisp.pl?gene=A1BG


Do scraping for “Genomic Locations for A1BG Gene”, you will see


Genomic Locations for A1BG Gene


chr19:58,345,178-58,353,492(GRCh38/hg38)


Size:8,315 bases


Orientation:Minus strand



Store the scrapped output into a file and rendered it in HTML as it looks in genecard




 


Write a PYTHON program 

  1. Create a data record in MySQL using patient meta data from <span style="font-size: 12pt; background-color: transparent; font-variant-numeric: normal; font-variant-east-asian: normal; text-decoration-line: underline; vertical-align: baseline;">https://repl.it/@<wbr>GaneshManoharan/<wbr>InstructiveChocolateLint#<wbr>PatientData.csv</span>
  2. Create a JSON and parse it through PHP and show the details in HTML 
  3. Provide a search option to filter the data


Common header of the csv would be


ID, Diagnosis Age,Sex,Ethnicity Category,Histology,Adjuvant Treatment,ECOG Performance Status,Smoking History,Person Cigarette Smoking History Pack Year Value,Relapse Free Status,Relapse Free Status (Months),Ubiquitous Assay Panel,Percent Necrosis,Tumor Volume (cm3),Tumar Stage



JSON format sample


Sample output in HTML

Have a global search to filter any columns/rows.


 

Note: Use BootStrap, JQUERY Data table and CSS to beautify the output.

LATEST TUTORIALS
APPROVED BY CLIENTS