The ONLY third party, smart Bluetooth stylus that I can, honestly, recommend that actually works well with any iPad is the Adonit Pixel for your 5th gen iPad.
https://www.adonit.net/jot/pixel/
This smart, Bluetooth stylus works across a wide range of iDevices.
The Bluetooth connection is stable and its Bluetooth pressure sensing technology is very smooth, natural feeling and has consistent line drawing ability.
Plus it's a quality made, aluminum stylus with two programmable buttons.
I have been using this stylus for well over two years now and it is really good on my iPad Pro.
This stylus works wonderfully for me.
The Adonit Pixel works with iPads all the way back to the 2012, 1st gen iPad Mini and iPad 4th generation!
Has ON/OFF/app shortcut buttons.
Has a nice fine, textured pen tip AND a nice rubber grip.
Magnetically charges, has an auto 15 minute shutdown feature ( to preserve battery life ), charges in a hour, or so.
Has both a small USB charger that that plugs into any USB charging block OR you can purchase an optional charging dock.
I find it only lasts for anywhere between 9-12 hours, but Adonit claims up to 16 hours of continuous use on a single charge cycle.
Made of very high quality aluminum materials.
The Adonit Pixel ONLY works with over a dozen of the major/popular drawing/sketching/painting apps (the Pixel works with, but currently no longer “officially” supported with Procreate, but it still works and works pretty well in Procreate ), and over a half dozen of the popular note taking apps, a half dozen writing apps and about a half dozen PDF style/compatible apps.
You WILL have to perform some pairing and setup parameters in each of the Adonit Pixel compatible apps.
You just DO NOT simply turn on Bluetooth on an iDevice and turn on the Adonit stylus and start writing.
The Adonit Pixel stylus is NOT an Apple Pencil in this regard/respect.
You have to initially Bluetooth pair the Adonit Pixel, setup the hand/palm position and in many apps, set up the stylus screen pressure sensitivity for each and every compatible app!
Once you have, initially, done all of this, all Adonit Pixel compatible apps will remember these settings for future use!
Some Adonit Pixel users claimed their stylus doesn’t work, but it does work well IF you properly know how to set up the Adonit Pixel!
If interested, to make sure you get the latest installed stylus firmware, you must order the Adonit Pixel stylus directly from the Adonit website, when possible and available.