Strings in Java

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

Use the following data file to answer this question which represents one long strand of DNA: http://www.cs.duke.edu/~rodger/GRch38dnapart.fa. How many times does the codon CTG appear in this strand of DNA?

224

Use the following data file to answer this question: http://www.cs.duke.edu/~rodger/GRch38dnapart.fa. How many genes in this file are longer than 60?

23

Use the following data file to answer this question: http://www.cs.duke.edu/~rodger/GRch38dnapart.fa. How many genes in this file have cgRatio greater than 0.35?

40

Use the following data file to answer this question: http://www.cs.duke.edu/~rodger/GRch38dnapart.fa. What is the length of the longest gene in the collection of genes found in this file?

489

Use the following data file to answer this question: http://www.cs.duke.edu/~rodger/GRch38dnapart.fa. How many genes are in this file?

69

Consider the following mystery method. public String mystery(String dna) { int pos = dna.indexOf("T"); int count = 0; int startPos = 0; String newDna = ""; if (pos == -1) { return dna; } while (count < 3) { count += 1; newDna = newDna + dna.substring(startPos,pos); startPos = pos+1; pos = dna.indexOf("T", startPos); if (pos == -1) { break; } } newDna = newDna + dna.substring(startPos); return newDna; } Which of the following best describes what it does?

The method mystery is given a string and it returns a string which is the same string but with the first three T's removed.

Consider finding all the YouTube links on a web page. What is the video for the second YouTube link on the web page http://www.dukelearntoprogram.com/course2/data/manylinks.html about? 1 point

Turkeys, Ducks and Quails


Kaugnay na mga set ng pag-aaral

Figurative Language Review 12/11

View Set

Chapter 9: Cellular Respiration and Fermentation

View Set

Leadership & Management Final Questions

View Set

Anatomy and Physiology Body Cavities and Regions

View Set

ch 11 administration of medication and intravenous therapy

View Set

Adult Development and Aging (Chapter 5)

View Set

Resources - satisfying our wants and needs.

View Set