How can I write that sentence in different colors? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 2

How can I write that sentence in different colors?

I mean,"I" in green,"am" in red,"limon" in purple color? pls give me the code

6th Aug 2016, 8:52 AM
Md. ABU JAR GIFARY LIMON
Md. ABU JAR GIFARY LIMON - avatar
2 Answers
+ 5
<p style="color:green;">I</p> <p style="color:red;">am</p> <p style="color:purple;">limon</p>
8th Aug 2016, 3:59 PM
freshnewname
freshnewname - avatar
+ 5
use tag "span", if you want inlined-text. or use "p", if you want paragraphed-text. <span style="color: green;">I</span>&nbsp; <span style="color: red;">am</span>&nbsp; <span style="color: purple;">limon</span> p.s. &nbsp; - non-breaking spaces
10th Aug 2016, 11:46 AM
Игорь Шин
Игорь Шин - avatar