Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;
//License from project: Open Source License 

import android.graphics.Color;

public class Main {
    public static int getScoreColor(float pc) {
        if (pc >= .8) {
            return Color.parseColor("#66FF66");
        } else if (pc >= .5) {
            return Color.parseColor("#E5E500");
        } else {
            return Color.parseColor("#FF0033");
        }
    }
}