Allowance for Doubtful Accounts (Detail) - Allowance for doubtful accounts - USD ($) $ in Millions |
12 Months Ended | ||
|---|---|---|---|
Jun. 30, 2020 |
Jun. 30, 2019 |
Jun. 30, 2018 |
|
| Valuation And Qualifying Accounts Disclosure [Line Items] | |||
| Balance, beginning of period | $ 434 | $ 397 | $ 361 |
| Charged to costs and other | 560 | 153 | 134 |
| Write-offs | (178) | (116) | (98) |
| Balance, end of period | 816 | 434 | 397 |
| Accounts receivable, net of allowance for doubtful accounts | |||
| Valuation And Qualifying Accounts Disclosure [Line Items] | |||
| Balance, beginning of period | 411 | 377 | |
| Balance, end of period | 788 | 411 | 377 |
| Other Long-term Assets | |||
| Valuation And Qualifying Accounts Disclosure [Line Items] | |||
| Balance, beginning of period | 23 | 20 | |
| Balance, end of period | $ 28 | $ 23 | $ 20 |