Main.java Source code

Java tutorial

Introduction

Here is the source code for Main.java

Source

//package com.java2s;

public class Main {
    public static String showPrintable(byte[] ra) {
        String s = new String();
        for (int i = 0; i < ra.length; i++) {
            char c = (char) ra[i];
            if (((c >= '0') && (c <= '9')) || ((c >= 'A') && (c <= 'Z')) || ((c >= 'a') && (c <= 'z'))) {
                s = s + c;
            } else {
                s = s + '.';
            }
        }
        return s;
    }
}