The D. C. public school system, the city agency hardest hit by layoffs and budget cuts, underspent its budget by $40,000 in the last fiscal year by slashing the cost of administration and overhead, according to a report by independent auditors.

An audit, submitted to the school board Monday by the nationally known accounting firm of Arthur Anderson & Co., showed that the school system, one of the biggest agencies in the deficit-plagued city government, spent $40,000 less than its $243.8 million appropriation in the fiscal year that ended Sept. 30.

The actual cost of operating the schools, the report shows, exceeded the budget by nearly $6.2 million, but the school system made up for most of that by under spending the allocation for "management services" by $5.7 million.

School officials, savoring the moment, said that proves that Mayor Marion Barry is wrong when he claims the school system is sacrificing classroom teachers and equipment to protect a top-heavy school bureaucracy. Barry, who has been involved in a long-running feud with the school system over the budget, has accused School Superintendent Vincent Reed and his staff of going "straight to the classroom" in their search for places to cut spending, a charge Reed has repeatedly denied.

The schools laid off more than 700 teachers at the beginning of this school year, but those figures are not reflected in the auditor's report, which covers the previous year.

James R. Boyle, finance director of the school system, said that "any time you can control down to $40,000 in a $240 million budget, you have very tight spending controls." He and other administrative officials made no secret of their satisfaction at a report showing that they stayed within their budget while other major city agencies were exceeding theirs.

Boyle attributed this partly to an internal computerized accounting system developed and operated by students at Ballou High School in Anacostia. The system -- an "on-line," operating computer program installed by the school system in its headquarters downtown and hooked up to the instructional computer at Ballou -- enables school officials to tell exactly at any given time how much money has been spent for any purpose and how much remains to be spent in the fiscal year.

For example, the school system computer records every out-of-town trip taken at the school's expense by every employee, coach and athlete, and it's costs, in clear, legible printouts. It tells which part of the school system the employe works for, where he or she went, and which source of funds is being charged for the cost, city appropriations for federal grants, or a combination of both.

That is exactly the kind of information that District government officials say they are unable to get from the highly complex computerized citywide accounting system known as FMS that Congress four years ago ordered installed to end the chaos in the city's bookkeeping. City officials have complained that FMS (Financial Management System) is so sophisticated that the people needed to run it would command the kind of salaries the city cannot afford to pay. The Ballou system is "so simple that the lowest clerk can operate it," said Pham Rung, the school system's chief accountant.

In effect, the school system has used its own resources to put students to work on a practical program that gives them valuable experience and enables Reed, Boyle, and their staffs to avoid dependence on FMS, which they regard as cumbersome and unreliable. They are required to record their financial transactions in the citywide system once they are made, but Boyle and Rung said they use the Ballou system, not FMS, to keep track of their accounts.

Dennis Johnson, principal of Ballou, said that "the kids have become computer nuts. They're finding out how bright they really are." He said the computer is available to every student and "they play games on it at their lunch hour. Even some of the students who have learning problems work on it. They find out it's a friend, not an enemy."

The auditors said the school system's financial statements "present fairly" its financial position, a testimonial to the accuracy of the school system's record keeping. The same accounting firm has been trying for four years to audit the city government's books but has been unable to validate enough information to deliver an "unqualified" or unequivocal opinion.

The lack of an audit has prevented the city from borrowing money in the bond market, and Congress ordered the development of FMS to make an audit possible. FMS has been in operation for 15 months, and the Andersen firm is expected to issue the first full audit of the District's books on Feb. 1.