首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何将字符串数组中的文本格式化为android的数学格式?

如何将字符串数组中的文本格式化为android的数学格式?
EN

Stack Overflow用户
提问于 2012-12-01 00:49:55
回答 1查看 305关注 0票数 0

我有一个应用程序,可以帮助人们学习微积分,我想让它看起来像实际的数学代码,而不是看起来像x^2+(x^1/2)-4的等式。项目中的代码如下。我对这个话题进行了研究,但我没有看到一个明确的解决方案。谢谢!

代码语言:javascript
复制
public class Limits extends Activity implements
    OnClickListener {
private static final int SWIPE_MIN_DISTANCE = 120;
private static final int SWIPE_MAX_OFF_PATH = 250;
private static final int SWIPE_THRESHOLD_VELOCITY = 200;
private GestureDetector gestureDetector;

View.OnTouchListener gestureListener;

String facts[] = {

//limits
"Find the limit as x approaches 0 of x^3+4x^2+6x+7",
"Find the limit as x approaches infinity of x/x^2",
"Find the limit as x approaches 3 of (x+3)^2/(x+6)",
"Find the limit as x approaches infinity of x^3/x",
"Find the limit as x approaches 3 of (x^2-6x+9)/(x-3)",
"Find the limit as x approaches 7 of 49x^2/7x",
"Find the limit as x approaches infinity of (2x^2-5x+3)/(x^2-7x+7)",
"Find the limit as x approaches 2 of (x − 2/x^2 − 19x + 34)",
"Find the limit as x approaches 6 of ((|x-6|)/(x-6))",

};

EN

回答 1

Stack Overflow用户

回答已采纳

发布于 2012-12-01 01:22:19

尝试使用HTML:

代码语言:javascript
复制
Html.fromHtml("X<sup>2</sup>")
票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/13649492

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档