[lab2] Cleanup

This commit is contained in:
Andrew Golovashevich 2026-01-30 03:02:49 +03:00
parent 8ae7321cd9
commit 762238d55c
2 changed files with 6 additions and 10 deletions

View File

@ -1,5 +1,5 @@
use std::cmp::min;
use std::ops::{BitAnd, BitAndAssign, Index, IndexMut, Not, Shl};
use std::ops::{BitAnd, BitAndAssign, Index, IndexMut};
pub struct BitVector {
data: Box<[bool]>,

View File

@ -4,10 +4,9 @@ mod algo;
use crate::algo::BitVector;
use eframe::egui;
use eframe::egui::{Align, Button, Ui};
use eframe::egui::Ui;
use eframe::emath::Numeric;
use egui_extras::{Column, TableBuilder};
use rand::SeedableRng;
use std::ops::RangeInclusive;
fn main() -> eframe::Result {
@ -16,7 +15,7 @@ fn main() -> eframe::Result {
..Default::default()
};
eframe::run_native(
"Annealing Simulation for Chess Queens Task",
"Adaptive Resonance Theory calculater",
options,
Box::new(|_cc| Ok(Box::<MyApp>::default())),
)
@ -158,15 +157,12 @@ impl eframe::App for MyApp {
ui.label("");
let mut tableBuilder = TableBuilder::new(ui)
TableBuilder::new(ui)
.striped(true) // Alternating row colors
.resizable(true)
.column(Column::remainder())
.column(Column::remainder());
for _ in 0..self.bitCount {
tableBuilder = tableBuilder.column(Column::auto());
}
tableBuilder
.column(Column::remainder())
.columns(Column::auto(), self.bitCount)
.header(20.0, |mut header| {
header.col(|ui| {
ui.horizontal(|ui| {