You can't display superscript in Apex code itself. If you want to display it elsewhere then you can use the sup HTML tag. This should display your # in superscript in rich text fields, HTML emails, and websites. Since normal text fields in Salesforce don't support HTML tags, you won't be able to use it there. Adding the tags is relatively easy:
String str = 'ABC#';
str = str.replaceAll('#', '<sup>#</sup>');
I hope that helps, if not, please clarify your question further.
PS: rich text fields don't support all HTML tags, here's a list of supported tags.