Swacblooms🦋

Making the Moves
Menu
  • Home
  • Motivation
  • Education
  • Programming
  • About
  • Contact
  • Privacy Policy
Home
Uncategorized
DNA Pairing
Uncategorized

DNA Pairing

Sammy March 29, 2019

The DNA strand is missing the pairing element. Take each character, get its pair, and return the results as a 2d array.

Base pairs are a pair of AT and CG. Match the missing element to the provided character.

Return the provided character as the first element in each array.

For example, for the input GCG, return [[“G”, “C”], [“C”,”G”],[“G”, “C”]]

The character and its pair are paired up in an array, and all the arrays are grouped into one encapsulating array.

Your code should satisfy the following conditions:

  • pairElement("ATCGA")should return [["A","T"],["T","A"],["C","G"],["G","C"],["A","T"]]
  • pairElement("TTGAG")should return [["T","A"],["T","A"],["G","C"],["A","T"],["G","C"]].
  • pairElement("CTCTA")should return [["C","G"],["T","A"],["C","G"],["T","A"],["A","T"]].

Try to establish your code using this function template:

Send link to your code in the comment section below. You can use any editor of your choice

Prev Article
Next Article

Related Articles

links
Hi folks, we are back and banging, I once talked …

Sharing node_modules on windows

resumable download
Hello 👋👋, so in this post, I will be writing …

Resumable Download in DotNet

About The Author

Sammy

I am Samson Amaugo. I am a full-stack web developer and I specialize in MERN stack development

One Response

  1. Sammy

    This is a link to my code
    https://code.sololearn.com/WVrimQnw8Kqp

    March 29, 2019

Leave a Reply

Cancel reply

Search Site

Recent Posts

  • Serving A VueJs App from DotNet
  • Dynamic Subscriptions in Hot Chocolate 🔥🍫
  • Deploying a DotNet API To Railway 🚂
  • GitHub OAuth Device Flow in DotNet
  • Resumable Download in DotNet

Categories

  • EDUCATION
  • Motivation
  • Programming
  • Uncategorized

Get more stuff

Subscribe to our mailing list and get interesting stuff and updates to your email inbox.

Thank you for subscribing.

Something went wrong.

we respect your privacy and take protecting it seriously

RSS Swacblooms

Swacblooms🦋

Making the Moves
Copyright © 2023 Swacblooms🦋
Swacblooms - Making the Moves