JSFiddle - React, Tailwind, and code Playground

by nukeboy212

HTML

<p>
Butt
</p>
<button id = "hi">
Press Me To Fix Butt
</button>

JavaScript

var bob = "abcdefg";
alert("OH NO! The Word butt is not right!")
alert("We will need to fix this! Click the button!")

function bobe(str, n){
var word = str.substring(0, 3)
var newWord = "";
  for(var i = 0; i < n; i ++){
  newWord += word;
}
  $("p").text(newWord)
  
}


$("#hi").click(function(){
bobe("Butt", 1)
$("#hi").text("Press Me To Fix But")
}) 
/*
var stuff = prompt("TYPE IN A WORD!!!!!!!!!!!!!!!!!!!!")
function bobebits(str){
var word = "";
for(var i = 0; i < stuff.length; i++){
if(i%2==0){
word += stuff[i]
}

}
$("p").text(word)
}
bobebits();
/*
*/
/*function pigLatin(str){
var chopped = str.substring(0,1)
var minusLetter = str(1,str.length)
var newWord = minusLetter += chopped ;

}