some codes by java or c++