Java tutorial
//package com.java2s; public class Main { public static float getCirclePathLength(float radius, float angle) { angle = changeAngleToSingle(angle); return (float) (Math.PI * radius * angle / 180); } public static float changeAngleToSingle(float angle) { while (angle >= 360) { angle -= 360; } while (angle < 0) { angle += 360; } return angle; } }