Skip to content

Instantly share code, notes, and snippets.

@JanBe
Last active October 4, 2017 08:00
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JanBe/2704c9cecbdab51d52785b057b7ded7a to your computer and use it in GitHub Desktop.
Save JanBe/2704c9cecbdab51d52785b057b7ded7a to your computer and use it in GitHub Desktop.
Coding Test
<html>
<head>
<script type='text/javascript' src='assessment.js'></script>
</head>
<body></body>
</html>
/* SMS can only be a maximum of 160 characters.
If the user wants to send a message bigger than that, we need to break it up.
We want a multi-part message to have this added to each message:
" - Part 1 of 2"
*/
// You need to fix this method, currently it will crash with > 160 char messages.
const sendSmsMessage = function sendSmsMessage (text, to, from) {
deliverMessageViaCarrier(text, to, from)
}
// This method actually sends the message via a SMS carrier
// This method works, you don't change it,
const deliverMessageViaCarrier = function deliverMessageViaCarrier (text, to, from) {
SmsCarrier.deliverMessage(text, to, from)
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment