The cost of the online program itself may qualify as a medical expense, but the cost of the computer would not.
Items that are primarily considered to be personal use items cannot be deducted as a medical expense even when used for a medical purpose.
To learn more, take a look at the IRS Publication 502 Medical Expenses. Under expenses that cannot be included, see the section for personal use items.