'Solana: calculate PDA in Java/Kotlin

I need to calculate PDA (Program Derived Address) using Java/Kotlin open-source libraries.

In Solana Web3 Javascript library there is an algorithm, which internally uses Tweetnacl-JS.

Unfortunately, my knowledge of cryptography is not enough to port this to Java.



Solution 1:[1]

I found an awesome Solana.kt library that has PDA calculation

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 ?????? ?????????