Question
Write down a function that creates a cell array and structure array and populate them with data about element weights and amino acid formula-
Using function header:
[ function [w s] = generate_array() ]
This function has no inputs. There are two outputs; w is the cell array of element weights and s is the structure array of amino acids.
In your function, generate a cell array w that stores molecular weight of each atom, with atom names in the first column and corresponding weights in the second.
In your function, generate a structure array that stores the formulation of each Amino Acid. Each element of the array should be a structure with 6 variables, one for amino acids name and one that stores the number of each atom that survive in the amino acids formula.