as per Accounting rules we should have to journalise and ledger the nature of accounts, whatever the transactions happened we should have to find out the first of all nature of accounts....
typically trading account is have what type of account what type of nature of accounts
🌟 ( To )describes credit and( By) describes Debit ..
Trading A/c is a nominal account. rules are Dr all expenses and credit all income. so on the debit side we write To and on the credit side we write By.