Individual genes are substrings of a genome

Assignment Help C/C++ Programming
Reference no: EM13164643

The DNA molecule employs a 4-element code consisting of sequences of the following nucleotides: Adenine,
Guanine, Cytosine and Thymine. Biologists often use a letter sequence to represent the genome, in which each
letter stands for one of the four nucleotides. For example:

. . . AGTCTATGTATCTCGTT . . .

Individual genes are substrings of a genome delineated by 3-element start and stop codons. Genes begin with
the start codon ATG and end with one of the following 3 stop codons: TAG, TAA or TGA. Note that start codons
can appear anywhere in the string, followed by a series of 3-element codons and ending with a stop codon.
Note that genes are multiples of 3 in length and do not contain any of the triples ATG, TAG, TAA or TGA.

Write a program that will read in a genome and display all the genes in the genome. Your program must do the
following:
• Include a function named genes that will take two arguments: a string containing a DNA sequence
as described above plus an integer reference parameter, and return a dynamically-allocated array of
strings containing all the genes in the DNA sequence. Each string in the array will contain a unique
gene. The number of elements in the array should be exactly equal to the number of genes in the
sequence and the number of genes found should be returned using the function's reference argument.
• Include a main function that will solicit a DNA sequence string from the user, call the genes function
to obtain all the genes in the sequence and print each one on the console display.

[Hint: there are many ways to do this, but you may find it easiest to perform two "passes" of the sequence. A
first pass to determine how many genes there are, and a second to construct the individual gene strings]

Example:
Enter a DNA sequence: TCATGTGCCCAAGCTGACTATGGCCCAATAGCG
Gene 1 TGCCCAAGC
Gene 2 GCCCAA

Reference no: EM13164643

Questions Cloud

Dynamic character arrays : Dynamic character arrays str and add contain strings. Write a function append that uses str and add as arguments and appends add to the end of str. Write a main program that illustrates the use of function append to concatenate five strings.
Multiply a set of complex numbers : Write a C program to multiply a set of complex numbers stored in an array (that has been dynamically allocated). Specifically, first prompt the user to enter how many complex numbers need to be multiplied, dynamically create an array to store the ..
Afterwards a way for the user to input : And so on and so forth then afterwards a way for the user to input that they finished a particular task on the list. After the user has input that they have finished a particular task the program should be print "Good Job!" or "Keep it up!"
User enters a list of car parts : So if the user enters a list of car parts, the programm holds this list. Afterward, when the user types in the name of the part the programm outputs that name from the list.
Individual genes are substrings of a genome : Individual genes are substrings of a genome delineated by 3-element start and stop codons. Genes begin with the start codon ATG and end with one of the following 3 stop codons: TAG, TAA or TGA. Note that start codons can appear anywhere in the string..
Function that accepts a pointer to a c-string : Write a function that accepts a pointer to a C-string as an argument and returns the number of words contained in the string. Also have it display the average number of letters in each word.
Write a program that prompts the user to enter the accounts : The program should pass these values to a function that returns the future value of the account after the specified number of months. The program should display the accounts future value.
Create a 1-dimensional (1d) array : Write a program to create a 1-dimensional (1D) array that contains 15 characters and display to the screen a count of the occurrences of each of the vowels a, e, i, o, and u in the array.
. write a segment of code that prints the number of elements : Assuming the array x has been defined as: int x[n]; for some n and that values have been assigned to all the elements. Write a segment of code that prints the number of elements between (but not including) the largest and smallest values in the array..

Reviews

Write a Review

C/C++ Programming Questions & Answers

  Create class having constructor to recieve two ints

Create a class (in C++)named Card. The class should have two int data members named face and suit.The class should have a constructor that recieves the two ints and uses them to initialize the data members.

  Write an lc-3 machine language program

Write an LC-3 machine language program starting at location x3000 which divides the number in memory location x4000 by the number in memory location x4001 and stores the quotient at x5000 and the remainder at x5001.

  Why does the neverwet spray protect it from water

As is know, acetone is a polar molecule like water, so isn't it suppose to mix? So my question is: why does the Neverwet spray protect it from water but not from oils and detergents?

  Two for loops that will calculate the sum of all even number

Write a program using two for loops that will calculate the sum of all even numbers between 2 and 100,

  Write a switch-case programming for calculation

How to use C++ to write a switch-case programming for calculation? Test the program for a wide range of possible inputs including division by zero and square root of negative values.

  Brownian motion is a physical phenomenon

Brownian motion is a physical phenomenon which can be observed, for instance, when a small particle is immersed in a liquid.

  Write program which reads n numbers from keyboard

Write down C++ program which reads N numbers (positive, negative, integer and double numbers) from keyboard, computes and shows the following information. Largest number of all numbers entered from keyboard.

  Write a function num_digits(n)

C programing, not C++ write a function num_digits(n) that returns the number of digits in a nonnegative integer n.

  Write c program-visual studio to scan multiple text files

Write program in C or C++ and Visual Studio to scan multiple text files and count number of occurrences of each word in those files. Use binary tree to keep track of all words.

  Create a file, shared.txt

When your program starts, it shall do the following:1. Create a file, SHARED.txt, in the current directory (cwd). 2. Write it's pid (Process ID) followed by a Carriage Return and Newline in the file.

  The funtion should take as parameters

Write a function in c ++ that multiplies two functions. the funtion should take as parameters two fraction structures. Then, the function should multiply the two fractions and return the solution as a fraction structure.

  Write down a program which will calculate and displays min

write down a program which will calculate and displays the min temperature and the maximum temperature for seven days of a week.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd